PulseHub
PINE LIBRARY

PINEOSCore

112
Library "PINEOSCore"

newEngine()
  Create a fresh structure engine.

marketText(trend)
  Trend label from structure state.
  Parameters:
    trend (int)

step(engine, swingLen, breakByClose, hi, lo, cls, bix, confirmed)
  Advance swing + structure engines by one bar. Mutates `engine`.
  Parameters:
    engine (Engine): Persistent engine state (`var` in consumer).
    swingLen (simple int): Pivot confirmation length (both sides).
    breakByClose (simple bool): When true, BOS requires close beyond swing.
    hi (float)
    lo (float)
    cls (float)
    bix (int)
    confirmed (bool)
  Returns: Snapshot of events and levels for the current bar.

Engine
  Mutable structure engine state (persist with `var` in consumer scripts).
  Fields:
    lastSwingHigh (series float)
    lastSwingLow (series float)
    prevSwingHigh (series float)
    prevSwingLow (series float)
    lastSwingHighBar (series int)
    lastSwingLowBar (series int)
    structureTrend (series int)
    lastStructureEvent (series string)

Snapshot
  Per-bar output from `step()` — read-only snapshot for products.
  Fields:
    bullBOS (series bool)
    bullCHOCH (series bool)
    bearBOS (series bool)
    bearCHOCH (series bool)
    rawBullBreak (series bool)
    rawBearBreak (series bool)
    newPivotHigh (series bool)
    newPivotLow (series bool)
    lastSwingHigh (series float)
    lastSwingLow (series float)
    prevSwingHigh (series float)
    prevSwingLow (series float)
    lastSwingHighBar (series int)
    lastSwingLowBar (series int)
    structureTrend (series int)
    lastStructureEvent (series string)

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by PulseWire. Read more in the Terms of Use.