| Neural Network Toolbox | |
| Provide feedback about this page |
Process data by marking rows with unknown values
Syntax
[y,ps] = fixunknowns(x) [y,ps] = fixunknowns(x,fp) y = fixunknowns('apply',x,ps) x = fixunknowns('reverse',y,ps) dx_dy = fixunknowns('dx',x,y,ps) dx_dy = fixunknowns('dx',x,[],ps) name = fixunknowns('name'); fp = fixunknowns('pdefaults'); names = fixunknowns('pnames'); fixunknowns('pcheck',fp);
Description
fixunknowns processes matrixes by replacing each row containing unknown values (represented by NaN) with two rows of information.
The first row contains the original row, with NaN values replaced by the row's mean. The second row contains 1 and 0 values, indicating which values in the first row were known or unknown, respectively.
fixunknowns(X) takes these inputs,
X |
Single N x Q matrix or a 1 x TS row cell array of N x Q matrices |
Y |
Each M x Q matrix with M - N rows added (optional) |
PS |
Process settings that allow consistent processing of values |
fixunknowns(X,FP) takes an empty struct FP of parameters.
fixunknowns('apply',X,PS) returns Y, given X and settings PS.
fixunknowns('reverse',Y,PS) returns X, given Y and settings PS.
fixunknowns('dx',X,Y,PS) returns the M x N x Q derivative of Y with respect to X.
fixunknowns('dx',X,[],PS) returns the derivative, less efficiently.
fixunknowns('name') returns the name of this process method.
fixunknowns('pdefaults') returns the default process parameter structure.
fixunknowns('pdesc') returns the process parameter descriptions.
fixunknowns('pcheck',fp) throws an error if any parameter is illegal.
Examples
Here is how to format a matrix with a mixture of known and unknown values in its second row:
Next, apply the same processing settings to new values:
Reverse the processing of y1 to get x1 again.
See Also
| Provide feedback about this page |
![]() | errsurf | gensim | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |