Skip to main content

Module point_figure

Module point_figure 

Source
Expand description

Point & Figure column construction (close-based, N-box reversal).

A Point & Figure chart discards time and volume and reduces price to a grid of boxes of height box_size. Price movement is drawn as columns: rising columns of X’s and falling columns of O’s. A column keeps extending while price advances by whole boxes, and a new (opposite) column starts only when price reverses by at least reversal boxes from the current column’s extreme — the classic N-box reversal filter (reversal = 3 is the traditional default).

This implements the close-price construction: each bar contributes its close, quantised to the box grid floor(price / box_size). On a reversal the new column begins one box back from the prior extreme (the standard top − 1 … top − N placement).

Sources:

  • Cohen, A. W. (1947), How to Use the Three-Point Reversal Method of Point & Figure Stock Market Trading — origin of the three-box (N-box) reversal.
  • du Plessis, J. (2012), The Definitive Guide to Point and Figure, 2nd ed. — modern box-size / reversal construction; the close-price method.

Two surfaces kept in parity (see the proptest):

Structs§

PointFigureBuilder
Stateful close-based Point & Figure builder.
PointFigureColumn
One completed Point & Figure column. direction is +1 (X, rising) or -1 (O, falling); top/bottom are the column’s high/low box levels (top >= bottom); boxes is the span between them in box_size units.

Functions§

point_figure_atr_batch
ATR-box Point & Figure: box size is multiplier * atr (a single representative ATR), matching the ATR-box convention of the other bar types.
point_figure_batch
Batch Point & Figure: fold PointFigureBuilder over a close slice.