XVALS

Purpose:

Returns the X values from a series.

Syntax:

XVALS(series, item, dt)

 

series

-

An input series

item

-

Optional. An integer, the series item. Defaults to 1, the primary item.

dt

-

Optional. An integer, the date/time format if the horizontal units are of date/time type.

0:

date/time relative to starting date/time (default)

1:

absolute date/time

Returns:

A new series or table containing the X values of the series.

Example:

W1: grand(5, 2)

xvals(W1)

 

returns the series {0.0, 2.0, 4.0, 6.0, 8.0}.

Example:

xvals(W1)

 

returns a series that consists of the X values of W1.

Example:

W1: grand(3, 1);settime("13:00");sethunits("time")

W2: xvals(w1)

W3: xvals(w1, 1, 1)

 

W1 contains the relative time values 0:00:00, 0:00:01, 0:00:02.

 

W2 contains the absolute time values 13:00:00, 13:00:01, 13:00:02.

Remarks:

The dt option applies to series with date or time horizontal units. For dt = 0, date values are relative to the starting date and time values are relative to the starting time.

 

Use IDX to return the indices of a series or array.

 

Use XTOIDX to convert X values to indices.

 

See XMINMAX to return the minimum and maximum X values of a series.

See Also:

IDX

SETHUNITS

XMINMAX

XY

XTOIDX

YVALS