public class PaceRegression extends Classifier implements OptionHandler, WeightedInstancesHandler, TechnicalInformationHandler
@phdthesis{Wang2000, address = {Hamilton, New Zealand}, author = {Wang, Y}, school = {Department of Computer Science, University of Waikato}, title = {A new approach to fitting linear models in high dimensional spaces}, year = {2000} } @inproceedings{Wang2002, address = {Sydney, Australia}, author = {Wang, Y. and Witten, I. H.}, booktitle = {Proceedings of the Nineteenth International Conference in Machine Learning}, pages = {650-657}, title = {Modeling for optimal probability prediction}, year = {2002} }Valid options are:
-D Produce debugging output. (default no debugging output)
-E <estimator> The estimator can be one of the following: eb -- Empirical Bayes estimator for noraml mixture (default) nested -- Optimal nested model selector for normal mixture subset -- Optimal subset selector for normal mixture pace2 -- PACE2 for Chi-square mixture pace4 -- PACE4 for Chi-square mixture pace6 -- PACE6 for Chi-square mixture ols -- Ordinary least squares estimator aic -- AIC estimator bic -- BIC estimator ric -- RIC estimator olsc -- Ordinary least squares subset selector with a threshold
-S <threshold value> Threshold value for the OLSC estimator
Modifier and Type | Field and Description |
---|---|
static Tag[] |
TAGS_ESTIMATOR
estimator types
|
Constructor and Description |
---|
PaceRegression() |
Modifier and Type | Method and Description |
---|---|
void |
buildClassifier(Instances data)
Builds a pace regression model for the given data.
|
boolean |
checkForMissing(Instance instance,
Instances model)
Checks if an instance has a missing value.
|
double |
classifyInstance(Instance instance)
Classifies the given instance using the linear regression function.
|
double[] |
coefficients()
Returns the coefficients for this linear model.
|
java.lang.String |
debugTipText()
Returns the tip text for this property
|
java.lang.String |
estimatorTipText()
Returns the tip text for this property
|
Capabilities |
getCapabilities()
Returns default capabilities of the classifier.
|
boolean |
getDebug()
Controls whether debugging output will be printed
|
SelectedTag |
getEstimator()
Gets the estimator
|
java.lang.String[] |
getOptions()
Gets the current settings of the classifier.
|
java.lang.String |
getRevision()
Returns the revision string.
|
TechnicalInformation |
getTechnicalInformation()
Returns an instance of a TechnicalInformation object, containing
detailed information about the technical background of this class,
e.g., paper reference or book this class is based on.
|
double |
getThreshold()
Gets the threshold for olsc estimator
|
java.lang.String |
globalInfo()
Returns a string describing this classifier
|
java.util.Enumeration |
listOptions()
Returns an enumeration describing the available options.
|
static void |
main(java.lang.String[] argv)
Generates a linear regression function predictor.
|
int |
numParameters()
Get the number of coefficients used in the model
|
void |
setDebug(boolean debug)
Controls whether debugging output will be printed
|
void |
setEstimator(SelectedTag estimator)
Sets the estimator.
|
void |
setOptions(java.lang.String[] options)
Parses a given list of options.
|
void |
setThreshold(double newThreshold)
Set threshold for the olsc estimator
|
java.lang.String |
thresholdTipText()
Returns the tip text for this property
|
java.lang.String |
toString()
Outputs the linear regression model as a string.
|
distributionForInstance, forName, makeCopies, makeCopy
public static final Tag[] TAGS_ESTIMATOR
public java.lang.String globalInfo()
public TechnicalInformation getTechnicalInformation()
getTechnicalInformation
in interface TechnicalInformationHandler
public Capabilities getCapabilities()
getCapabilities
in interface CapabilitiesHandler
getCapabilities
in class Classifier
Capabilities
public void buildClassifier(Instances data) throws java.lang.Exception
buildClassifier
in class Classifier
data
- the training data to be used for generating the
linear regression functionjava.lang.Exception
- if the classifier could not be built successfullypublic boolean checkForMissing(Instance instance, Instances model)
instance
- the instancemodel
- the datapublic double classifyInstance(Instance instance) throws java.lang.Exception
classifyInstance
in class Classifier
instance
- the test instancejava.lang.Exception
- if classification can't be done successfullypublic java.lang.String toString()
toString
in class java.lang.Object
public java.util.Enumeration listOptions()
listOptions
in interface OptionHandler
listOptions
in class Classifier
public void setOptions(java.lang.String[] options) throws java.lang.Exception
-D Produce debugging output. (default no debugging output)
-E <estimator> The estimator can be one of the following: eb -- Empirical Bayes estimator for noraml mixture (default) nested -- Optimal nested model selector for normal mixture subset -- Optimal subset selector for normal mixture pace2 -- PACE2 for Chi-square mixture pace4 -- PACE4 for Chi-square mixture pace6 -- PACE6 for Chi-square mixture ols -- Ordinary least squares estimator aic -- AIC estimator bic -- BIC estimator ric -- RIC estimator olsc -- Ordinary least squares subset selector with a threshold
-S <threshold value> Threshold value for the OLSC estimator
setOptions
in interface OptionHandler
setOptions
in class Classifier
options
- the list of options as an array of stringsjava.lang.Exception
- if an option is not supportedpublic double[] coefficients()
public java.lang.String[] getOptions()
getOptions
in interface OptionHandler
getOptions
in class Classifier
public int numParameters()
public java.lang.String debugTipText()
debugTipText
in class Classifier
public void setDebug(boolean debug)
setDebug
in class Classifier
debug
- true if debugging output should be printedpublic boolean getDebug()
getDebug
in class Classifier
public java.lang.String estimatorTipText()
public SelectedTag getEstimator()
public void setEstimator(SelectedTag estimator)
estimator
- the new estimatorpublic java.lang.String thresholdTipText()
public void setThreshold(double newThreshold)
newThreshold
- the threshold for the olsc estimatorpublic double getThreshold()
public java.lang.String getRevision()
getRevision
in interface RevisionHandler
getRevision
in class Classifier
public static void main(java.lang.String[] argv)
argv
- the options