Extracts a portion of a series or table.
EXTRACT(series, start, length, offset)
series |
- |
A series or table. |
start |
- |
An integer value for the starting point. |
length |
- |
An integer value for the number of points to be extracted. |
offset |
- |
Optional. A real, the X |
A series or table.
extract(W1, 1, 512)
extracts the first 512-point subset series from Window 1. This is equivalent to
W1: 1..10
W2: extract(W1, 4, 3)
results is the series {4, 5, 6}. The DELTAX remains the same while the XOFFSET is equal to 3, the x-value of the 4th point.
W1: gnorm(100, 1)
W2: extract(W1, 1, 2 * length(W1))
copies the series from W1 to W2 and pads it with enough zeros to equal two times the original series length.
W1: gnorm(100, 1)
W2: extract(W1, 10, -1)
extracts from W1 points 10 through the end of the series.
W2: extract(W1, 10, -1, 0.0)
Same as above, except the XOFFSET of the result is set to 0.0.
If start is negative, zeros are prepended to the result. If the number of points to extract is greater than the series or table length, the result is padded with zeros.
See COLEXTRACT to extract a column specific number of points from each column of an array.
See EXTRACTWIN to extract a section of a series from multiple Windows.
See SEREXTRACT to extract multiple sections from the same series.
See XEXTRACT to extract a section of a series based on X values.