Hi,
This wiki page has provided some examples on how to access data from worksheet. For your issue, you can try the following code.
void accessData()
{
Worksheet wks = Project.ActiveLayer();
if(!wks)
return;
Column colY1 = wks.Columns(1); // Y1 column
if(!colY1)
return;
vector& vecColY1 = colY1.GetDataObject(); // get data of Y1 column
for(int iCol=2; iCol<wks.Columns.Count(); iCol++)
{
Column colYiCol = wks.Columns(iCol);
if(!colYiCol)
continue;
vector& vecColYiCol = colYiCol.GetDataObject();
vecColYiCol = vecColYiCol-vecColY1; // Y(n)=Y(n)-Y(1)
}
}
Penn