Encodemodelbuilder

From Eigenvector Research Documentation Wiki
Revision as of 12:19, 15 October 2014 by imported>Donal (→‎Description)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Purpose

Create MATLAB m-code which will regenerate a given model

Synopsis

encodemodelbuilder(model, filename)

Description

Given the input of a standard model structure, this function creates a file which can be used to regenerate a model with the exact options and conditions used to create the model. The resulting function can be used to document how a model was built, or can be used to build new models from new or otherwise modified data. The function is written to take only the inputs required for data blocks for the modeling method (e.g. PCA requires 1, PLS requires 2). For example, if the output file is called "mymodel" and was a PLS model, a new model could be built using:

model = mymodel(x,y)

Remember that the performance of two models built using the same preprocessing and meta-parameter choices but different input data will give different results. Such model building "formulas" should be used with care. Validation of all models is highly recommended.

Inputs

  • model = variable containing a standard PLS_Toolbox model structure.

Optional Inputs

  • filename = An optional filename to which the build code should be written. If omitted, the user will be prompted for a filename and folder.

See Also

encodexml, encode