Search...Ctrl K

Timeframes

Coming Soon — MTTP is currently in development. This documentation is published early so you can explore what's ahead.

MTTP tracks ten timeframe levels using two fundamentally different detection methods. Understanding how each works helps you interpret what the labels actually mean.


Two Detection Paradigms

Period-Based Detection

Eight timeframes use period accumulation: bars are collected until a period boundary is reached, then the completed period is classified.

The process:

  1. Accumulate bars as they arrive
  2. Track running high, low, open, close
  3. Detect when period ends (hour boundary, week end, month end, etc.)
  4. Compare completed period to previous period
  5. Classify: Higher High, Lower Low, Outside Bar, or Inside Bar
  6. Apply swing detection rules (same as SSI PRO)
  7. If swing confirms, place label at the extreme bar

Count-Based Detection

Two timeframes use consecutive bar counting: watch for directional persistence, confirm the previous extreme when the count threshold is met.

The process:

  1. Classify each daily bar (up, down, inside, outside)
  2. Count consecutive bars in the same direction
  3. When count reaches threshold (2 or 3), confirm the previous opposite extreme
  4. Place label at the confirmed swing bar

Period-Based Timeframes

Intraday Periods (15min, 1hr, 4hr)

These accumulate chart bars until the target duration is reached. The boundaries align to actual exchange times, not arbitrary bar counts.

Example: 4-Hour on a 1-Hour Chart

If exchange hours start at 9:30 AM:

  • First 4hr period: 9:30 AM - 1:30 PM
  • Second 4hr period: 1:30 PM - 5:30 PM
  • And so on...

When four 1-hour bars complete, MTTP captures the period's OHLC and classifies it against the previous 4-hour period.

Why exchange alignment matters:

Without it, your 4-hour periods would shift based on when you loaded the chart. With exchange alignment, the same 4-hour swing appears at the same bar regardless of when you opened TradingView.

<!-- IMAGE: mttp-4hr-alignment.png — 1-hour chart showing 4H labels at consistent exchange-aligned boundaries -->

Daily

Daily periods follow trading day boundaries. On intraday charts, bars accumulate until the trading day ends, then the daily period is evaluated.

On a daily chart, each bar IS a daily period — no accumulation needed. MTTP classifies bar-by-bar using the standard swing detection logic.

Weekly

Weekly periods accumulate daily bars until the trading week ends (typically Friday close for most markets).

What defines a "week":

  • Standard markets: Monday open → Friday close
  • Crypto/Forex: Sunday open → Friday close (or 24/7 continuous)

When five trading days complete, the weekly period captures the week's high, low, open, and close, then classifies against the previous week.

Monthly

Monthly periods follow calendar month boundaries. Daily bars accumulate until the last trading day of the month, then the monthly period is evaluated.

Edge case handling:

  • Partial months at chart start: Waits for first full month
  • Holidays: Uses actual trading days, not calendar days

Quarterly

Quarterly periods follow calendar quarters:

  • Q1: January - March
  • Q2: April - June
  • Q3: July - October
  • Q4: October - December

Three months of data accumulate, then the quarterly period is classified against the previous quarter.

Yearly

Yearly periods follow calendar years. Twelve months of data accumulate, then the yearly period is classified.

On long-term charts, yearly swings reveal major structural turning points — bull market peaks, bear market bottoms, multi-year ranges.

<!-- IMAGE: mttp-yearly-swings.png — Monthly chart showing Y labels at major yearly turning points -->

Count-Based Timeframes

The Gann Multi-Day Methodology

W.D. Gann's swing charting rules include a concept often called "2-day" and "3-day" swings. Instead of waiting for a period to complete, these methods count consecutive directional bars.

The principle: When price moves persistently in one direction, the previous extreme in the opposite direction becomes more significant. The count threshold determines how much persistence is required.

2-Day Swings

Confirms swings after 2 consecutive directional bars.

How it works:

  1. Watch each daily bar's classification
  2. An "up bar" has both a higher high AND higher low than the previous bar
  3. A "down bar" has both a lower high AND lower low than the previous bar
  4. When 2 consecutive up bars occur, the previous down extreme confirms as a swing low
  5. When 2 consecutive down bars occur, the previous up extreme confirms as a swing high

Example sequence:

Bar 1: Down bar (lower high, lower low) Bar 2: Down bar (lower high, lower low) ← 2 consecutive down → Previous high confirmed as swing high, label placed Bar 3: Up bar (higher high, higher low) Bar 4: Inside bar (ignored, doesn't break count) Bar 5: Up bar (higher high, higher low) ← 2 consecutive up → Previous low confirmed as swing low, label placed
<!-- IMAGE: mttp-2day-sequence.png — Daily chart showing 2D confirmation sequence -->

3-Day Swings

Confirms swings after 3 consecutive directional bars.

Same logic as 2-Day, but requires more persistence. This filters out minor fluctuations and shows only swings with stronger directional commitment.

When to use each:

  • 2-Day: More responsive, shows smaller structural swings
  • 3-Day: More filtered, shows only significant directional moves

Both can run simultaneously on the same chart with different colors, revealing nested swing structure within the daily timeframe.

Daily Chart Only

Count-based detection only makes sense on daily charts. On intraday charts, "consecutive daily bars" has no meaning — you'd need the daily bar to complete first, which defeats the purpose.

When you're on a daily chart, enable 2-Day and/or 3-Day alongside your period-based timeframes. When you're on any other timeframe, these options are automatically hidden.


Classification Rules

Both detection methods use the same underlying classification once a period or bar is ready to evaluate:

Higher High (HH)

  • High is higher than previous period's high
  • Low is higher than previous period's low
  • Indicates bullish bar/period

Lower Low (LL)

  • High is lower than previous period's high
  • Low is lower than previous period's low
  • Indicates bearish bar/period

Outside Bar (OB)

  • High is higher than previous period's high
  • Low is lower than previous period's low
  • Indicates expansion, resolution depends on next bar

Inside Bar (IB)

  • High is lower than previous period's high
  • Low is higher than previous period's low
  • Indicates contraction, state frozen until penetration

OB Continuation Modes

Each timeframe has its own OB Continuation setting with three options:

Mark Zigzag (Default)

When an OB continues the prior trend, mark both:

  1. The pre-OB turning point
  2. The OB's extreme in the opposite direction

This creates a small zigzag pattern within the OB, showing the internal structure.

Mark as Reversal

When an OB continues the prior trend, mark only the OB's extreme. Treats the OB as a single reversal point rather than showing the internal zigzag.

Skip Entirely

Don't mark OB continuations at all. Only reversals (where the OB ends the prior trend) are marked.


State Isolation

Each timeframe maintains completely independent state:

  • Its own swing detection state (current trend, last marked type)
  • Its own OB resolution state (pending OBs, prior trend)
  • Its own accumulation data (running OHLC, bar count)
  • Its own label array (for dynamic window management)

This isolation ensures that activity in one timeframe never affects another. A Weekly swing confirming has no impact on Monthly detection, and vice versa.


Boundary Detection Details

Calendar-Based (Monthly, Quarterly, Yearly)

Uses actual calendar boundaries:

  • Month changes when month(time) != month(time[1])
  • Quarter changes when month crosses Q boundary (Mar→Apr, Jun→Jul, Sep→Oct, Dec→Jan)
  • Year changes when year(time) != year(time[1])

Bar-Based (15min, 1hr, 4hr, Daily, Weekly)

Uses time-in-seconds calculations:

  • 15min: Every 900 seconds of accumulated time
  • 1hr: Every 3600 seconds of accumulated time
  • 4hr: Every 14400 seconds of accumulated time
  • Daily: Trading day boundary (market-specific)
  • Weekly: End of trading week (typically Friday)

The key insight: boundaries are detected on every bar, not assumed. This handles holidays, half-days, and irregular sessions correctly.


Next Steps