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, trainprotected java.util.regex.Pattern Regex
protected boolean IncludeMatching
public void setOptions(java.util.List<java.lang.Object> Options)
throws java.lang.Exception
OptionsOptions - Array of options as Objects - can be nulljava.lang.Exception - if problem with inputspublic java.lang.String printUsage()
Optionspublic void setRegex(java.lang.String regex)
throws java.util.regex.PatternSyntaxException
regex - Regular expression to be matchedjava.util.regex.PatternSyntaxExceptionpublic void setIncludeMatching(boolean x)
x - Desired operationprotected java.util.List<java.lang.Integer> train_protected(Dataset Data)
BaseAttributeSelectortrain_protected in class BaseAttributeSelectorData - Dataset used to train selectorpublic java.lang.String printDescription(boolean htmlFormat)
PrintableExample: For a model training a separate WekaRegression for intermetallics
magpie.models.regression.SplitRegression
printDescription in interface PrintableprintDescription in class BaseAttributeSelectorhtmlFormat - Whether format for output to an HTML page
(e.g., <div> to create indentation) or for printing to screen.#printModel()