XYRange::GetErrColumn

Description

To get Y Error column of XYRange

Syntax

BOOL GetErrColumn( Column & col, int nIndex = 0, int* pr1 = NULL, int* pr2 = NULL)

Parameters

col
[output]the Y Error column
nIndex
[input]the data index
pr1
[output]if not NULL, will get row range
pr2
[output]if not NULL, will get row range

Return

TRUE if success.

Examples

EX1

// Assume there are three columns in the active sheet.
// Output the sum ot the ED column.
void XYRange_GetErrColumn_Ex1()
{
    Worksheet wks;
    wks= Project.ActiveLayer();
    XYRange xyData;
    if( wks )
    {
        xyData.Add("X", wks, 0, 0, -1, 0);
        xyData.Add("Y", wks, 0, 1, -1, 1);
        xyData.Add("ED", wks, 0, 2, -1, 2);
 
        Column colErr;
        int nIndex = 0;
        xyData.GetErrColumn(colErr, nIndex);
        vectorbase &vv = colErr.GetDataObject();
        double dd;
        vv.Sum(dd);
        printf("sum of vector is %f\n", dd);    
        
    }    
}

Remark

See Also

XYRange::GetXColumn, XYRange::GetYColumn

header to Include

origin.h