# Bart Pattern

Detects regular and inverted Bart patterns (flat ranges bookended by abrupt vertical moves) using median-filtered edge detection. Settings control edge sensitivity, range flatness, and display mode, including a meme-free simple view. A retrospective study tool for traders examining how these volatile formations tend to resolve.

- Indicator in the LuxAlgo Library, by LuxAlgo, published Apr 12, 2022.
- Access: free.
- Concepts: [Bart Pattern](https://www.luxalgo.com/library/concept/bart-pattern/) (primary), [Reversal](https://www.luxalgo.com/library/concept/reversal/), [Trading Range](https://www.luxalgo.com/library/concept/trading-range/)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=cmpwn0dj6000jvhsg9opktn8v
- Page: https://www.luxalgo.com/library/indicator/bart-pattern/

**Bart Pattern** hunts the meme-famous formation (a violent vertical move, a flat shelf, then an equally abrupt move back the other way) in both regular and inverted form. Using median-filtered edge detection, it marks historical structures that so often resolve in a sharp [reversal](https://www.luxalgo.com/library/concept/reversal/), giving traders a way to study how these shapes behave. Detection is retrospective rather than real-time.

## How to Trade the Bart Pattern?

- **Completed patterns**: review what followed each historical Bart. These formations often precede quick price movements, making them context for anticipating volatility.
- **Shelf edges**: before completion, a breakout beyond support or resistance formed inside the flat section is the tradeable event, approached with caution, since sudden jumps are common around these structures.
- **Inverted Barts**: toggle them on to catch the drop, shelf, and recovery mirror image.

The [Bart pattern](https://www.luxalgo.com/library/concept/bart-pattern/) itself is a meme-born formation from around 2018, most at home on crypto charts, with causes still debated (over-leveraged participants for some, exchange spoofing for others), which is exactly why the detector favors careful study over blind entries. Prefer charts without cartoons? A simple display mode drops the meme visuals entirely.

## Bart Pattern Settings

- **Median Lookback**: lookback of the median filter behind edge detection; shorter periods find shorter, less spaced patterns.
- **Edge Detection Sensitivity**: higher values decrease sensitivity to low-magnitude edges.
- **Range To Edges Threshold**: lower values require flatter ranges between the two edges.
- **Show Inverted Barts**: includes inverted formations in the display.
- **Mode**: how detected patterns are drawn, including the simple meme-free option.

## Frequently Asked Questions

### Does the Bart Pattern detect in real time?

No. Patterns are identified after completion, which makes the tool a study aid: evaluate how similar conditions resolved historically and carry that context into live trading decisions.

### Is there a related novelty pattern tool?

Yes. The Bart's rise to fame ran parallel to the golden arches, and the [McDonald's Pattern](https://www.luxalgo.com/library/indicator/mcdonalds-pattern/) indicator covers that one. Both are playful builds with genuinely usable detection logic underneath.

### Is the Bart Pattern indicator free?

Completely. It lives in the free LuxAlgo Library, and from this page you can also load it into Quant, our coding agent, to scan history for Barts on your favorite symbols. You can also copy the source code from this page and run it anywhere Pine Script® runs.

## Related indicators

- [Reversal Signals](https://www.luxalgo.com/library/indicator/reversal-signals/) (Reversal): markdown at https://www.luxalgo.com/library/indicator/reversal-signals.md
- [Reversal Candlestick Structure](https://www.luxalgo.com/library/indicator/reversal-candlestick-structure/) (Reversal): markdown at https://www.luxalgo.com/library/indicator/reversal-candlestick-structure.md
- [Range Detector](https://www.luxalgo.com/library/indicator/range-detector/) (Trading Range): markdown at https://www.luxalgo.com/library/indicator/range-detector.md
- [Wave Consolidation](https://www.luxalgo.com/library/indicator/wave-consolidation/) (Trading Range): markdown at https://www.luxalgo.com/library/indicator/wave-consolidation.md
- [N Bar Reversal Detector](https://www.luxalgo.com/library/indicator/n-bar-reversal-detector/) (Key Reversal): markdown at https://www.luxalgo.com/library/indicator/n-bar-reversal-detector.md
- [Head & Shoulders](https://www.luxalgo.com/library/indicator/head-and-shoulders/) (Chart & Candlestick Patterns): markdown at https://www.luxalgo.com/library/indicator/head-and-shoulders.md
- [Wolfe Wave Detector](https://www.luxalgo.com/library/indicator/wolfe-wave-detector/) (Wolfe Waves): markdown at https://www.luxalgo.com/library/indicator/wolfe-wave-detector.md
- [Island Reversal](https://www.luxalgo.com/library/indicator/island-reversal/) (Chart & Candlestick Patterns): markdown at https://www.luxalgo.com/library/indicator/island-reversal.md

---

Source: https://www.luxalgo.com/library/indicator/bart-pattern/ (LuxAlgo Library). Free to use with attribution: https://www.luxalgo.com/library/license/
