Setplspref
Purpose
Set overriding options (preferences) for PLS_Toolbox functions.
Synopsis
- setplspref(mfile,options)
- setplspref(mfile,option,value)
- setplspref(mfile,'factory') %reset preferences for specified file
- setplspref('factory') %reset all preferences to factory settings
Description
Sets user-defined "overriding default options" for a PLS_Toolbox function. These preferences will, for a given function, override any factory-default options of the same name. Any option which is defined in the factory-defaults but not specified in the user-defined default options will remain at the factory-default setting.
The keyword 'factory' can be used to reset all or some of the options back to the factory default values: When given as the mfile name (mfile) then all preferences for all functions will be reset; when given as the options structure (options), then all options for the named function will be reset. When given as the value for a specified option, only that option's default is reset.
See below for other input forms.
Inputs
- mfile = the function name for which preferences are being set.
The subsequent inputs can be one of three forms:
- Form 1:
- options = a structure to use as the overriding default options forthe given function. Any previous overriding options are erased.
- Form 2:
- option = a string defining the option to set. Any other overriding options for this mfile are left alone and only that one option is changed.
- value = a value for the particular option
- Form 3:
- option = a string defining the option to set. Any other overriding options for this mfile are left alone and only that one option is changed.
- 'factory' = the string 'factory' resets the speicified option to the factory default.
Examples
options = []; options.plots = 'none'; setplspref('pca',options) setplspref('pca','plots','none'); setplspref('pca','factory');