Skip to main content
Track Session analysis
18 / 18
Library

2016issue C0517-20

Session-gated moving-average entry construction

Archive construction marks regular-session hours so the open can later constrain coded rules, writes entry, gain-taking, and loss-exit as one strategy, and adds a simple moving average last. Lookback length is the main overlay control. A tighter linear-regression curve fit is a different goal from executable rules.

  • A closer mathematical fit to price is not the same construction goal as writing executable entry and exit rules.
  • Color regular-session and overnight bars differently, and place vertical dividers at the night-to-day and day-to-night boundaries, so session state is readable as a filter.
  • Chart overlays do not generate entries. Only an explicit buy-and-sell recipe produces signals.
  • On a simple moving average, length is the main construction control. A length of 15 turns more slowly than a length of 5.
Entries in this reading3 entries

An editorial construction order

Editorial note: TradersWeek reads the archive workflow as a build order. Lock the hours that may generate signals, write entry, target, and stop as one procedure, and treat moving-average length as a forecast smoother rather than as the tightest curve through the bars.

Mark the open as a session filter

Regular-session and overnight bars can be colored differently so the open is visible at a glance. A worked example treats the regular session as 6:30 to 13:15 Pacific time.

Vertical dividers can mark the night-to-day and day-to-night boundaries so session state is readable as a filter. Session identification is meant to become a constraint inside later coded rules, not only a chart annotation.

Write one strategy, not an indicator signal

Chart overlays do not generate entries. Only an explicit buy-and-sell recipe produces signals.

A complete strategy statement specifies when to enter, when to take a gain if the trade is right, and when to exit if the trade is wrong. An indicator is a curve, line, or mark overlaid on a chart and does not issue buy or sell commands.

Choose length for smoothness, not a tighter fit

A closer mathematical fit to price is not the same construction goal as writing executable entry and exit rules. On the same series, a simple moving average is smoother and looser, while a linear-regression curve fit tracks the bars more tightly.

A linear-regression line can be drawn over a chosen bar count, including a 300-bar example. Using fewer bars concentrates the fit on more recent data.

A single-line simple moving average can take price, length, and displacement as input values, with length as the main construction control. A worked example uses a length of 9. That lookback length is the number of bars sent into the average. A length of 15 yields a smoother, slower-turning average than a length of 5, which tracks price more closely.

Weekly Dow: 9-week SMA versus linear-regression curve

The teal 9-week average stays smoother and looser than the red linear-regression curve, which tracks weekly Dow bars more tightly. That is the construction lesson: choose length so the overlay is a slower forecast, not the tightest fit through the last print. Levels were read from the TradeStation $INDU weekly figure; the final SMA print of 17,947.84 comes from the platform header.
The teal 9-week average stays smoother and looser than the red linear-regression curve, which tracks weekly Dow bars more tightly. That is the construction lesson: choose length so the overlay is a slower forecast, not the tightest fit through the last print. Levels were read from the TradeStation $INDU weekly figure; the final SMA print of 17,947.84 comes from the platform header.Dow Jones Industrial Average ($INDU) · Weekly · 2012-06-01T00:00:00.000Z to 2015-07-31T00:00:00.000Z

Platform header fixes the moving average at Close, length 9, displace 0. Digitized points are approximate to the nearest 50 index points except that final SMA print. The visible window runs from mid-2012 through mid-2015; year ticks on the axis were used to place the x values.

Educational research material, not investment advice. Historical source context does not establish present-day performance.
18 of 18 in the Session analysis track
1986Track finished · Next track: Sharpe ratioAuditing stochastic crossovers with moving-average baselines24 readings
All readings on this track · 18 readings
  1. 1990Constructing a second-hour session residual exponential index
  2. 2000Treat an open limit book as an execution filter
  3. 2002Constructing a long, short, or flat pre-trade checklist
  4. 2003Session-window trims for mechanical day-system evaluation
  5. 2004Overnight session entry rules after regular hours
  6. 2005Overnight and regular session execution in Nasdaq 100 names
  7. 2006The intraday workspace as a combined decision procedure
  8. 2006Same-session trading needs presence and next-signal rules
  9. 2007Session filters for moving-average entry rules
  10. 2008Related-market checklist, session filter, and ATR-scaled stop
  11. 2008After-hours session regimes and the next-day close
  12. 2008Evaluating a next-open entry after one-day corrections
  13. 2010Session range share: currency futures versus the mini index
  14. 2011Dollar travel, afternoon sessions, and a 1:2 first-loss bound in equity-index futures
  15. 2012Last-hour volume breaks with a first-hour exit
  16. 2013Same-session and multi-session trades as one rule-based procedure
  17. 2015Session clock bars from public quote feeds
  18. 2016Session-gated moving-average entry construction
All 42 readings tagged Session analysis
Also on Session analysis5 readings