fintech-algorithms
Using a coding agent? Give it the skill: npx skills add IslamBaraka90/Fintech-Algorithms-Library What it does →

Two-Candle Patterns

12 algorithms in Price Action and Candlesticks · 12 with asserted arithmetic.

In this family#

  1. Bullish Engulfing verified

    Evaluates two candles against explicit bullish-engulfing geometry, scale, and downtrend context conventions.

    bullishEngulfing(inputs)
  2. Bearish Engulfing verified

    Evaluates two candles against explicit bearish-engulfing geometry, scale, and uptrend context conventions.

    bearishEngulfing(inputs)
  3. Bullish Harami verified

    Evaluates two candles against explicit bullish-harami containment, scale, and downtrend context conventions.

    bullishHarami(inputs)
  4. Bearish Harami verified

    Evaluates two candles against explicit bearish-harami containment, scale, and uptrend context conventions.

    bearishHarami(inputs)
  5. Piercing Line verified

    Evaluates two candles against explicit piercing-line gap, midpoint, scale, and downtrend conventions.

    piercingLine(inputs)
  6. Dark Cloud Cover verified

    Evaluates two candles against explicit dark-cloud gap, midpoint, scale, and uptrend conventions.

    darkCloudCover(inputs)
  7. Tweezer Top verified

    Evaluates two candles against explicit tweezer-top tolerance, rejection, scale, and uptrend conventions.

    tweezerTop(inputs)
  8. Tweezer Bottom verified

    Evaluates two candles against explicit tweezer-bottom tolerance, rejection, scale, and downtrend conventions.

    tweezerBottom(inputs)
  9. Harami Cross verified

    Scans consecutive pairs of bars for a doji whose body sits inside the previous bar's body, and reports the pattern's direction from the colour of that earlier bar.

    haramiCross(input)
  10. Kicking Pattern verified

    Scans consecutive pairs of bars for two near-marubozu candles of opposite colour separated by a clean gap, with no overlap between the two ranges.

    kickingPattern(input)
  11. Matching Low verified

    Scans consecutive pairs of bars for two down candles whose closes land within a tick of each other, marking a repeated closing floor.

    matchingLow(input)
  12. Rising/Falling Window verified

    Scans consecutive pairs of bars for a price gap, where the second bar's range clears the first bar's entirely in either direction.

    risingFallingWindow(input)

What they share#

Every topic here is a record-transform, so once you have called one the rest follow the same shape. Import paths differ only in the final segment:

ts
import { bullishEngulfing } from "fintech-algorithms/price-action-and-candlesticks/two-candle-patterns/bullish-engulfing";
import { bearishEngulfing } from "fintech-algorithms/price-action-and-candlesticks/two-candle-patterns/bearish-engulfing";

Read them in the order above — the sequence is pedagogical, not alphabetical.

Where this sits#

Price Action and Candlesticks collects 52 algorithms across 5 families. For the concept behind this family rather than the call signatures, see the concept guides.