3.5.8.18 Plotdata

Description

This function returns the designated dataset of the index number plot at (colNum, rowNum) panel of the active layer.

Syntax

dataset plotdata(int nIndex, int nDesignation, int colNum = 0, int rowNum = 0, int m = 0, int n = 0)

Parameter

nIndex

Index number of plot, which can be:
  • plot index, e.g. 1 for the plot listed first in the layer (more about plot order).
  • asterisk (*) which denotes all plots in layer.
  • asterisk-dash (*-) which denotes all plots in layer except fitted curves.

nDesignation

The column type enum
  • X: X Value
  • Y: Y Value
  • Z: Z Value
  • XE: X Error
  • YE: Y Error

colNum

The column number of panel.

rowNum

The row number of panel.

m(Origin 2025)

level of horizontal panel.

n(Origin 2025)

level of vertical panel.

Return

Return the designated dataset of the index number plot at (colNum, rowNum) panel.

Example

Example1

newbook;
fname$ = system.path.program$ + "Samples\Curve Fitting\Multiple Gaussians.dat";
impASC;
plotxy iy:=(1,2:end) plot:=200;
allymean = Mean(plotdata(*, Y)) ; //Get the mean value of all plots’ Y value
allymean =;
y1max = Max(plotdata(1,Y));
y1max =;

Example2

newbook;
fname$ = system.path.program$ + "Samples\Data Manipulation\WeatherStations.DAT";
impASC;
plot_group iy:=col(6) type:=3 horz:=col(5) vert:=col(4);
sunnymean = Mean(plotdata(1, Y, 5, *)); 
sunnymean=;
wilmottmax = Max(plotdata(1,Y,*,2));
wilmottmax=;