Yes, it is possible to do that. We can add an extra column to the worksheet and uses it to control the shape of the data points.
It is just like using the Plot Detail dialog to have Origin use a column as the shape indexing. If indexing is zero, the symbol will not show; if indexing value is 1, the symbol will be a square; for 2, the shape will be circle...

In Origin C, we can add a column for shape indexing to the worksheet, fill it with proper numbers, change the format of the graph page so as to set the column for shape indexing of the scatter plot.
For example, the following program can "place a square symbol on every 10th point and the remove the symbols on the rest of the points" as you have requested.
void test5018()
{
//Get the active graph layer
GraphLayer gl=Project.ActiveLayer();
if (!gl) return;
//Get dataset name for the first dataplot
DataPlot dp=gl.DataPlots(0);
string strName = dp.GetDatasetName();
//Find the name of worksheet and the index of the column
int iPos=strName.Find('_');
Worksheet wks(strName.Left(iPos));
string strColName = strName.Right(strName.GetLength()-iPos-1);
int iIndexCol1=wks.Columns(strColName).GetIndex();
//Add a new column
string strColNameCreated;
wks.AddCol("shape", strColNameCreated);
Column colCreated = wks.Columns(strColNameCreated);
int iIndexCol2=colCreated.GetIndex();
//Set values
colCreated.SetFormula("rmod(i,10)==0?1:0");
colCreated.ExecuteFormula();
//Get format of the graph page
GraphPage pg = gl.GetPage();
Tree tr;
tr = pg.GetFormat(FOB_PLOT, FPB_STYLE_SYMBOL_SHAPE);
//Get the tree node for symbol shape
TreeNode tn;
tn=tree_get_node_by_attributes(tr, "NodeID", "143");
if (!tn.IsValid()) return;
//Set properties
tn.nVal=iIndexCol2-iIndexCol1+100;
//Apply the changed format
pg.ApplyFormat(tr);
}
You can change the formula as you need in the line:
colCreated.SetFormula("rmod(i,10)==0?1:0");
Deanna
OriginLab GZ Office
Edited by - Deanna on 08/10/2006 01:42:34 AM