images/contents.gifimages/index.gifimages/prev1.gifimages/next1.gif

Semantics

Before you begin using the Formula Evaluator, it is important that you make the distinction between a single number and a data series.

The expression,

IBM.close

should not be thought of as a single number (the most recent IBM close), but as a data series consisting of closing prices, one for each IBM bar. In theory, this series of closes extends infinitely into the past and future. In reality, we dont yet know future closes, and, generally, we arent too concerned with closes in the distant past. We do, however, care about the series of closes visible in a chart window.

Some expressions can be thought of as computations on single numbers. Take, for example, the expression:

IBM.high-IBM.low

In one sense, you can think of this expression in terms of the current high and low, i.e., subtract IBMs current low from IBMs current high.

In another sense, you can also look at this expression as an operation on a data series, i.e., subtract the series of IBM lows from the series of IBM highs to create a new series. The reason you can look at this simple expression two ways is that, either way, the operation is pointwise. If you look at it as a single number, the expression only makes sense if you subtract the current low from the current high. If you look at the expression as a data sereies, each element of the output series depends only on the corresponding element of the input series. The expression interpreted as an operation on a single bar accurately describes what happens to each high and low in the series of IBM bars.

Some study functions, however, are not completely pointwise operations.