|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnz.ac.waikato.mcennis.rat.graph.model.ModelShell
nz.ac.waikato.mcennis.rat.graph.algorithm.machinelearning.MultiInstanceSVM
public class MultiInstanceSVM
Derive globally using the same data as the AddMusicRecommendation algorithm. Takes the weka classifier as a parameter. See execute for how the propositionalization is performed.
Field Summary |
---|
Fields inherited from class nz.ac.waikato.mcennis.rat.graph.model.ModelShell |
---|
listener |
Constructor Summary | |
---|---|
MultiInstanceSVM()
Creates a new instance of OutputARFF |
Method Summary | |
---|---|
protected void |
addInstances(Graph g,
weka.core.Instances dataSet,
Actor artist,
int skipCount,
int positiveSkipCount)
|
protected int |
countTotal(Graph g)
|
protected weka.core.Instances |
createDataSet(Actor[] artists)
|
protected void |
evaluateClassifier(weka.classifiers.Classifier classifier,
weka.core.Instances dataSet,
Graph g,
Actor toBePredicted)
|
protected boolean |
evaluateResult(int count,
int total)
|
void |
execute(Graph g)
Generate music predictions for a user as follows: Calculate all artists A present in the data set. |
protected weka.classifiers.Classifier |
getClassifier()
|
InputDescriptor[] |
getInputType()
The input type describes all the different kinds of graph objects that are utilized (and hence required) by this object. |
OutputDescriptor[] |
getOutputType()
The output type describes all the different kinds of graph objects that are created during the execution of this algorithm. |
Parameter[] |
getParameter()
List of all parameters this component accepts. |
Parameter |
getParameter(java.lang.String param)
Returns the specific parameter identified by its key-name. |
SettableParameter[] |
getSettableParameter()
Returns settable (i.e. |
SettableParameter |
getSettableParameter(java.lang.String param)
Return the settable parameter namede by this key-name. |
void |
init(java.util.Properties map)
Paramters are defined as follows: 'name' - name for this instance of this algorithm. |
int |
totalYes(Graph g,
Actor a)
|
Methods inherited from class nz.ac.waikato.mcennis.rat.graph.model.ModelShell |
---|
addListener, fireChange |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface nz.ac.waikato.mcennis.rat.graph.model.Model |
---|
addListener |
Constructor Detail |
---|
public MultiInstanceSVM()
Method Detail |
---|
public void execute(Graph g)
execute
in interface Algorithm
g
- graph to be modifiedprotected void evaluateClassifier(weka.classifiers.Classifier classifier, weka.core.Instances dataSet, Graph g, Actor toBePredicted) throws java.lang.Exception
java.lang.Exception
protected boolean evaluateResult(int count, int total)
public int totalYes(Graph g, Actor a)
protected int countTotal(Graph g)
protected weka.core.Instances createDataSet(Actor[] artists)
protected void addInstances(Graph g, weka.core.Instances dataSet, Actor artist, int skipCount, int positiveSkipCount)
protected weka.classifiers.Classifier getClassifier()
public InputDescriptor[] getInputType()
Component
getInputType
in interface Component
InputDescriptor
public OutputDescriptor[] getOutputType()
Component
getOutputType
in interface Component
OutputDescriptor
public Parameter[] getParameter()
Component
getParameter
in interface Component
public Parameter getParameter(java.lang.String param)
Component
getParameter
in interface Component
param
- key-name of the parameter
public SettableParameter[] getSettableParameter()
Component
getSettableParameter
in interface Component
public SettableParameter getSettableParameter(java.lang.String param)
Component
getSettableParameter
in interface Component
param
- key-name of the parameter
public void init(java.util.Properties map)
init
in interface Component
map
- map of the given properties naming parameters and their values in a string
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |