| 2.1.24.2.6 ocmath_sign_test
 DescriptionPerforms a Sign test for related samples. The main engine is nag_sign_test. This is an OriginPro only function.
 Syntaxint ocmath_sign_test( const double * pData1, const double * pData2, const uint nSize, const int nTailType, int * nTies, NPHFreqs * SignFreqs, NPHStats * SignStats ) Parameters pData1[input] pointer to 1st data points pData2[input] pointer to 2nd data points nSize[input] size of 1st and 2nd data points nTailType[input] value indicates Tail Type. which containing 3 types:TAILED_TEST_TWO is 0,TAILED_TEST_UPPER is 1,TAILED_TEST_LOWER is 2 nTies[output] pointer to number of ties SignFreqs[output] pointer to structure containing Statistics of Frequencies SignStats[output] pointer to structure containing the test statistic and p-value. No corrected for ties.
 ReturnReturns STATS_NO_ERROR on successful exit or an STATS error code on failure.
 ExamplesEX1
 void ocmath_sign_test_ex1()
{
    vector pData1 = {1.0, 2.3, 4.5, 2.0, 5.3};
    vector pData2 = {2.2, 5.6, 4.3, 1.7, 3.8};
    int nSize = pData1.GetSize();
    int nTailType = TAILED_TEST_TWO;
    int nTies;
    NPHFreqs SignFreqs;
    NPHStats SignStats;
    
    int nRet = ocmath_sign_test(pData1, pData2, nSize, nTailType, &nTies, &SignFreqs, &SignStats);
    out_int("nRet=", nRet);
}RemarkSee AlsoHeader to Includedorigin.h
 Reference |