2.2.3.9.3 matrixbase::AnyNANUM

Contents

Description

Indicates whether or not each row or column of this matrix contains any NANUM(missing value) elements.

Syntax

int AnyNANUM( vector<BOOL> & vAnyNANUM, int nDim = 1)

Parameters

vAnyNANUM
[output] The result vector
nDim
[input] The AnyNANUM test can occur row wise (relative to the first dimension when nDim=1) or column wise (relative to the second dimension when nDim=2)

Return

Returns 0 on success and a non-zero error code on failure.

Examples

EX1

void test_AnyNANUM()
{
    vector<BOOL> vRowHasAnyNANUM;
	matrix<double> mat1 = {
        {1, 1, 0,  1,  1,  0, NANUM},
        {1, 1, 0,  1, NANUM, NANUM, NANUM},
        {1, 0, 0, NANUM, NANUM, NANUM, NANUM}
    };
    int rc=mat1.AnyNANUM(vRowHasAnyNANUM);
}

Remark

See Also

matrixbase::AnyNonZero, matrixbase::AllNonZero, matrixbase::AllNANUM

Header to Include

origin.h