Enables user-defined items to be added to the preprocess catalog.
Each method available in the preprocess function has an associated 'methodname' such as those listed in the help for preprocess. Each method is defined using a preprocessing structure that contains all the necessary information to perform calculations for that method. The standard methods are defined in the preprocatalog file, which should not be edited by the user. Additional user-defined methods can be defined in the preprouser file and the following text describes how the user can add custom preprocessing methods. A few example methods already exist in the preprouser file to guide the user. In addition, details of the structure are given on the User Defined Preprocessing page. Note, standard preprocessing methods cannot change the dimension of the data being processed, nor the include fields if it is a dataset. This is a PLS_Toolbox convention and must also apply to custom user-defined preprocessing methods.
To add a custom user-defined preprocessing method, the user must
- open the PREPROUSER.M file
- edit the file to create a structure
- after defining the structure, add the line preprocess('addtocatalog',fig,usermethod)
- save and close the PREPROUSER.M file.
The line added in Step 3
makes the new custom method available to preprocess. The input usermethod is the preprocessing structure containing the user-defined method, and fig is a figure handle passed to PREPROUSER by preprocess.
The methods defined in the preprocatalog and preprouser files are available to all functions making use of the preprocess function.
Note that once a method is defined, a copy of that preprocessing method can be saved to a MAT file which can be loaded and used in another user's PLS_Toolbox, Solo, or Solo_Predictor without having to define the preprocessing structure themselves.
Important Note: Please make your preprocessing structure and "usermethod" names distinctive to avoid problems where loaded variables clash with existing variables. In particular do not use a name like "preprocess" as this will cause problems.