|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectweka.gui.boundaryvisualizer.EMDataGenerator
Class that uses EM to build a probabilistic clustering model of supplied input data and then generates new random instances based that model.
Constructor Summary | |
EMDataGenerator()
|
Method Summary | |
void |
buildGenerator(Instances inputInstances)
Builds the data generator |
Instance |
generateInstance()
Generate a new instance. |
Instance |
generateInstanceFast()
Generate a new instance. |
int |
getClusterUsedToGenerateLastInstanceFrom()
Return the number of the cluster from which the next instance will be generated from |
EM |
getEMModel()
Return the EM model of the data |
int |
getNumGeneratingModels()
Return the number of clusters generated by EM |
static void |
main(java.lang.String[] args)
Main method for tesing this class |
void |
setWeightingDimensions(boolean[] dims)
Set which dimensions to use when computing a weight for the next instance to generate |
void |
setWeightingValues(double[] vals)
Set the values for the weighting dimensions to be used when computing the weight for the next instance to be generated |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public EMDataGenerator()
Method Detail |
public void buildGenerator(Instances inputInstances) throws java.lang.Exception
buildGenerator
in interface DataGenerator
inputInstances
- Instances to construct the clusterer with
java.lang.Exception
- if an error occurspublic Instance generateInstance() throws java.lang.Exception
generateInstance
in interface DataGenerator
Instance
value
java.lang.Exception
- if an error occurspublic Instance generateInstanceFast() throws java.lang.Exception
generateInstanceFast
in interface DataGenerator
Instance
value
java.lang.Exception
- if an error occurspublic void setWeightingDimensions(boolean[] dims)
setWeightingDimensions
in interface DataGenerator
dims
- an array of booleans indicating which dimensions to usepublic void setWeightingValues(double[] vals)
setWeightingValues
in interface DataGenerator
vals
- an array of doubles containing the values of the
weighting dimensions (corresponding to the entries that are set to
true throw setWeightingDimensions)public EM getEMModel()
EM
valuepublic int getNumGeneratingModels()
getNumGeneratingModels
in interface DataGenerator
int
valuepublic int getClusterUsedToGenerateLastInstanceFrom()
int
valuepublic static void main(java.lang.String[] args)
args
- a String[]
value
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |