📄 miscomb.m
字号:
% MISCOMB - Find combinations of missing values in columns%% [ nobscomb, obscombj, Isv ] = MISCOMB(M,verbose) computes the% combinations of missing values in each column of a data matrix.% This is needed for faster implementation.%% See also PCA_FULL, PCA_PT, LSPCA% This software is provided "as is", without warranty of any kind.% Alexander Ilin, Tapani Raikofunction [ nobscomb, obscombj, Isv ] = miscomb(M,verbose)n2 = size(M,2);if verbose fprintf( 'Calculating Isv ... ');end[tmp, I, Isv] = unique( M', 'rows' ); % Transpose of M may be heavynobscomb = size(tmp,1); % or length(I) % or max(Isv);if nobscomb < n2 obscombj = cell(nobscomb, 1); for i = 1:n2 obscombj{Isv(i)} = [obscombj{Isv(i)}; i]; endelse obscombj = {}; Isv = [];endif verbose fprintf('done\n'); fprintf( 'Missing values combinations: found %d in %d columns\n',... nobscomb, n2 )end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -