Skip to content
Home
← All projects

Market Scanner

Screens the S&P 500 for uptrend tickers by SMA stacking, relative volume, and ATR — running unattended on scheduled GitHub Actions that refresh, scan, and commit results back to the repo.

  • Python
  • Massive API
  • GitHub Actions

The problem

Screening the S&P 500 by hand does not scale, and the parts that make it tedious are exactly the parts a machine is good at: pull the current universe, fetch daily prices for every name, apply the same arithmetic to each, and write down what came out. Done manually it is an hour of clicking that produces a result which is stale the next morning.

The goal was a scanner that runs without me — no laptop open, no button pressed, no server to babysit.

Approach

Each trading day the pipeline refreshes the S&P 500 universe, fetches daily price history from the Massive market-data API, and flags tickers in an uptrend on three independent criteria:

  • SMA stacking — shorter moving averages sitting above longer ones, the standard structural definition of a trend rather than a single-day move
  • Relative volume — today's volume against the ticker's own recent baseline, so conviction is measured per-name instead of by an absolute share count that would only ever surface megacaps
  • ATR — average true range, to characterize volatility rather than treat a 2% move in a quiet name and a volatile one as the same event

Running unattended

The scheduler is GitHub Actions, which is the part of this project I would defend hardest. There is no server, nothing to patch, and nothing to pay for. A scheduled workflow refreshes the universe, fetches prices, runs the scan, and commits the results back to the repository — so the repo's own git history becomes the record of what the scanner saw on each day, versioned for free, with no database to run.