Note that this reference documentation is identical to the help that is displayed in Matlab when you type “help ft_checkopt”.
FT_CHECKOPT does a validity test on the types and values of a configuration structure or cell-array with key-value pairs. Use as opt = ft_checkopt(opt, key) opt = ft_checkopt(opt, key, allowedtype) opt = ft_checkopt(opt, key, allowedtype, allowedval) For allowedtype you can specify a string or a cell-array with multiple strings. All the default MATLAB types can be specified, such as 'double' 'logical' 'char' 'single' 'float' 'int16' 'cell' 'struct' 'function_handle' Furthermore, the following custom types can be specified 'doublescalar' 'doublevector' 'doublematrix' 'numericscalar' 'numericvector' 'numericmatrix' 'charcell' For allowedval you can specify a single value or a cell-array with multiple values. This function will give an error or it returns the input configuration structure or cell-array without modifications. A match on any of the allowed types and any of the allowed values is sufficient to let this function pass. See also FT_GETOPT, FT_SETOPT
Share this page: