public class RegexAttributeSelector extends BaseAttributeSelector
Usage: [-v] <Regex>
If the Regex includes spaces, surround with ""s
Modifier and Type | Field and Description |
---|---|
protected boolean |
IncludeMatching
Whether to include attributes that match
|
protected java.util.regex.Pattern |
Regex
Regular expression to be matched
|
trained
Constructor and Description |
---|
RegexAttributeSelector() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
printDescription(boolean htmlFormat)
Print full name of object, and a simple description of the options.
|
java.lang.String |
printUsage()
Print out required format for options.
|
void |
setIncludeMatching(boolean x)
Set whether to include (or exclude) attributes whose name matches the pattern.
|
void |
setOptions(java.util.List<java.lang.Object> Options)
Set any options for this object.
|
void |
setRegex(java.lang.String regex)
Define the regular expression.
|
protected java.util.List<java.lang.Integer> |
train_protected(Dataset Data)
Operation that actually does the work for training.
|
about, applyAttributeSelection, clone, getSelectionNames, getSelections, isTrained, printCommand, printSelections, run, runCommand, train
protected java.util.regex.Pattern Regex
protected boolean IncludeMatching
public void setOptions(java.util.List<java.lang.Object> Options) throws java.lang.Exception
Options
Options
- Array of options as Objects - can be null
java.lang.Exception
- if problem with inputspublic java.lang.String printUsage()
Options
public void setRegex(java.lang.String regex) throws java.util.regex.PatternSyntaxException
regex
- Regular expression to be matchedjava.util.regex.PatternSyntaxException
public void setIncludeMatching(boolean x)
x
- Desired operationprotected java.util.List<java.lang.Integer> train_protected(Dataset Data)
BaseAttributeSelector
train_protected
in class BaseAttributeSelector
Data
- Dataset used to train selectorpublic java.lang.String printDescription(boolean htmlFormat)
Printable
Example: For a model training a separate WekaRegression for intermetallics
magpie.models.regression.SplitRegression
printDescription
in interface Printable
printDescription
in class BaseAttributeSelector
htmlFormat
- Whether format for output to an HTML page
(e.g., <div> to create indentation) or for printing to screen.#printModel()