public class Complejo
extends java.lang.Object
implements java.lang.Comparable
Stores conjunctions of selectors
Constructor and Description |
---|
Complejo()
Default constructor.
|
Complejo(int nClas)
Constructor for Complex
|
Modifier and Type | Method and Description |
---|---|
void |
addSelector(Selector s)
Add the selector into the selector list
|
void |
adjuntaNombreAtributos(java.lang.String[] atributos)
Local copy of the name of variables
|
void |
ajustaDistrib()
Normalizes the distribution values [0, 1]
|
void |
borraDistrib()
reset the distribution value for the complex
|
int |
compareTo(java.lang.Object o)
Compare two objects of the class
|
boolean |
cubre(Muestra m)
Checks if the complex covers the given sample.
|
boolean |
esIgual(Complejo c)
Check if two complex are equals (represent the same)
|
int |
getClase()
Returns the class value
|
double[] |
getDistribucion()
Return the value of the distribution
|
double |
getDistribucionClase(int clase)
Return the value of the distribution
|
int |
getDistribucionClaseEj(int clase)
Return the value of the distribution for the given class
|
int[] |
getDistribucionEj()
Return the value of the distribution
|
double |
getHeuristica()
return the heuristic value of the complex
|
int |
getNClases()
Return the number of classes
|
Selector |
getSelector(int indice)
Return a selector in one position by giving a complex
|
void |
incrementaDistrib(int clase)
Add one to the n of the complex for the class
|
void |
print()
Print the content of the complex (List->Attribute operator value)
|
void |
printDistribucion()
Print the classes distribution for the complex
|
java.lang.String |
printDistribucionString()
Print the classes distribution for the complex
|
java.lang.String |
printString()
Returns a string with the complex contents (List -> Attribute operator value).
|
void |
setClase(int clase)
Sets the given value as class.
|
void |
setHeuristica(double heu)
Assign a heuristic value (Wracc) to the complex
|
int |
size()
Return the size complex
|
public Complejo()
public Complejo(int nClas)
nClas
- int number of classespublic int compareTo(java.lang.Object o)
Compare two objects of the class
compareTo
in interface java.lang.Comparable
o
- complex to comparepublic boolean esIgual(Complejo c)
Check if two complex are equals (represent the same)
c
- El complex to comparepublic void addSelector(Selector s)
Add the selector into the selector list
s
- the selector (set atr. op. value)public Selector getSelector(int indice)
Return a selector in one position by giving a complex
indice
- Position inside the complexpublic int size()
Return the size complex
public int getNClases()
Return the number of classes
public int getClase()
public void setClase(int clase)
clase
- int given value to set.public boolean cubre(Muestra m)
m
- given sample.public double getHeuristica()
return the heuristic value of the complex
public void setHeuristica(double heu)
Assign a heuristic value (Wracc) to the complex
heu
- heuristic valuepublic void borraDistrib()
reset the distribution value for the complex
public void incrementaDistrib(int clase)
Add one to the n of the complex for the class
clase
- int value of the classpublic void ajustaDistrib()
public double getDistribucionClase(int clase)
Return the value of the distribution
clase
- int index of the classpublic double[] getDistribucion()
Return the value of the distribution
public int getDistribucionClaseEj(int clase)
Return the value of the distribution for the given class
clase
- given classpublic int[] getDistribucionEj()
Return the value of the distribution
public void print()
public java.lang.String printString()
public void printDistribucion()
Print the classes distribution for the complex
public java.lang.String printDistribucionString()
Print the classes distribution for the complex
public void adjuntaNombreAtributos(java.lang.String[] atributos)
Local copy of the name of variables
atributos
- String[] stores the name of the variables