Hmac: Difference between revisions
(11 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
===Purpose=== | ===Purpose=== | ||
Hierarchical Model Automatic Classifier | Hierarchical Model Automatic Classifier. Creates a decision tree of PLSDA models calibrated on classification data following the [https://doi.org/10.1002/cem.3455 AHIMBU] method (Marchi, Lorenzo, et al. “Automatic Hierarchical Model Builder.” Journal of Chemometrics, vol. 36, no. 12, 17 Nov. 2022.). | ||
See more about Modelselector models [[Modelselector]]. | See more about Modelselector models [[Modelselector]]. | ||
Modelselector models may be built from the command line/scripting, but are constructed much more easily in our [[Hierarchical Model Builder]] interface. | |||
See [https://www.wiki.eigenvector.com/index.php?title=Hierarchical_Model_Builder#Automatic_Hierarchical_Model_Classification Automatic Hierarchical Model Classification] to use Hmac in the Hierarchical Model Builder interface. | See [https://www.wiki.eigenvector.com/index.php?title=Hierarchical_Model_Builder#Automatic_Hierarchical_Model_Classification Automatic Hierarchical Model Classification] to use Hmac in the Hierarchical Model Builder interface. | ||
===Synopsis=== | |||
: hmacInstance = Hmac(); | |||
: hmacInstance = hmacInstance.setX(x); | |||
: hmacInstance = hmacInstance.setY(y); | |||
: options = hmacInstance.getOptions; | |||
: hmacInstance = hmacInstance.setOptions(options); | |||
: hmacInstance = hmacInstance.calibrate; | |||
: modelselectorgui(hmacInstance.model); | |||
===Description=== | ===Description=== | ||
Build a Modelselector model | Build a Modelselector model from input dataset X, or input X and Y if classes are not already supplied in the X dataset. | ||
Each node in the resulting Modelselector model will be a PLSDA model that was calibrated on all or | Each node in the resulting Modelselector model will be a PLSDA model that was calibrated on all or a subset of classes from a given class set. | ||
This works by peeling off one or few classes at a time and creating a PLSDA model for each split | This works by peeling off one or a few classes at a time and creating a PLSDA model for each split. The algorithm is completed when all classes are accounted for or there is perfect classification. | ||
there is perfect classification. | |||
====Inputs==== | ====Inputs==== | ||
Line 33: | Line 33: | ||
====Outputs==== | ====Outputs==== | ||
* ''' | * '''hmacInstance''' = an object of class Hmac, contains 'model' field which is the resulting Modelselector model. | ||
====Cross-validation==== | ====Cross-validation==== | ||
Cross-validation can be applied to each PLSDA node model. The CV settings are the same for each node, the default being Venetian Blinds, 10 splits, and 1 Sample per blind. | Cross-validation can be applied to each PLSDA node model. The CV settings are the same for each node, the default being Venetian Blinds, 10 splits, and 1 Sample per blind. | ||
From the Hierarchical Model Builder interface, customize the CV settings by clicking on the Cross-Validation | From the Hierarchical Model Builder interface, customize the CV settings by clicking on the 'Cross-Validation Set' button in the Hmac interface. | ||
====Preprocessing==== | ====Preprocessing==== | ||
Like the | Like the cross-validation options, the X-block preprocessing settings will be the same across all of the potential PLSDA models in the final Modelselector model. | ||
===Options=== | ===Options=== | ||
Line 49: | Line 49: | ||
* '''maxlvs''': [ {6} ] Maximum number of latent variables to use in crossval (see crossval), | * '''maxlvs''': [ {6} ] Maximum number of latent variables to use in crossval (see crossval), | ||
* '''cvopts''' : struct of cross-validation options, including preprocessing at each node in the modelselector model. See [https://www.wiki.eigenvector.com/index.php?title=Crossval#Options here] for all available options, | * '''cvopts''' : struct of cross-validation options, including preprocessing at each node in the modelselector model. See [https://www.wiki.eigenvector.com/index.php?title=Crossval#Options here] for all available options, | ||
* '''cvi''' : [{'vet' 10 1}] Standard cross-validation cell (see crossval) defining a split method, number of splits, and number of iterations. This cross-validation is for splitting each class or subclasses in the | * '''cvi''' : [{'vet' 10 1}] Standard cross-validation cell (see crossval) defining a split method, number of splits, and number of iterations. This cross-validation is for splitting each class or subclasses in the AHIMBU algorithm. | ||
===See Also=== | ===See Also=== | ||
[[Modelselector]], [[Hierarchical Model Builder]], [[analysis]], [[crossval]], [[preprocess]], [[EVRIModel_Objects]] | [[Modelselector]], [[Hierarchical Model Builder]], [[analysis]], [[crossval]], [[preprocess]], [[EVRIModel_Objects]] |
Latest revision as of 10:41, 17 January 2023
Purpose
Hierarchical Model Automatic Classifier. Creates a decision tree of PLSDA models calibrated on classification data following the AHIMBU method (Marchi, Lorenzo, et al. “Automatic Hierarchical Model Builder.” Journal of Chemometrics, vol. 36, no. 12, 17 Nov. 2022.).
See more about Modelselector models Modelselector.
Modelselector models may be built from the command line/scripting, but are constructed much more easily in our Hierarchical Model Builder interface.
See Automatic Hierarchical Model Classification to use Hmac in the Hierarchical Model Builder interface.
Synopsis
- hmacInstance = Hmac();
- hmacInstance = hmacInstance.setX(x);
- hmacInstance = hmacInstance.setY(y);
- options = hmacInstance.getOptions;
- hmacInstance = hmacInstance.setOptions(options);
- hmacInstance = hmacInstance.calibrate;
- modelselectorgui(hmacInstance.model);
Description
Build a Modelselector model from input dataset X, or input X and Y if classes are not already supplied in the X dataset. Each node in the resulting Modelselector model will be a PLSDA model that was calibrated on all or a subset of classes from a given class set. This works by peeling off one or a few classes at a time and creating a PLSDA model for each split. The algorithm is completed when all classes are accounted for or there is perfect classification.
Inputs
- x = X-block (predictor block) class "double" or "dataset", containing numeric values,
- y = Y-block (optional) class "double" sample class values,
- options = an optional input options structure (see below)
Outputs
- hmacInstance = an object of class Hmac, contains 'model' field which is the resulting Modelselector model.
Cross-validation
Cross-validation can be applied to each PLSDA node model. The CV settings are the same for each node, the default being Venetian Blinds, 10 splits, and 1 Sample per blind.
From the Hierarchical Model Builder interface, customize the CV settings by clicking on the 'Cross-Validation Set' button in the Hmac interface.
Preprocessing
Like the cross-validation options, the X-block preprocessing settings will be the same across all of the potential PLSDA models in the final Modelselector model.
Options
options = a structure array with the following fields:
- classset : [ {1} ], Indicates which class set in x to use when no y-block is provided,
- maxlvs: [ {6} ] Maximum number of latent variables to use in crossval (see crossval),
- cvopts : struct of cross-validation options, including preprocessing at each node in the modelselector model. See here for all available options,
- cvi : [{'vet' 10 1}] Standard cross-validation cell (see crossval) defining a split method, number of splits, and number of iterations. This cross-validation is for splitting each class or subclasses in the AHIMBU algorithm.
See Also
Modelselector, Hierarchical Model Builder, analysis, crossval, preprocess, EVRIModel_Objects