Trade or Sit Out? A Data-Driven Market Decision Engine

AfraSimon
03-19

I made a "should I be trading?" dashboard.

Scores the market across 5 pillars:

- volatility (put/call ratio, vix, positioning)

- trend (spx vs 20d, 50d, 200d ma's)

- breadth (advancing/declining, nas highs/lows)

- momentum (sector leaders, laggards, % participation)

- macro (fomc, rates, geopolitics)

Each is weighted, combined, and averaged to give me a score for the current environment.

Basically a yes, no, or stay small.

Sometimes I just need someone (or something) to remind me to stay out.

Happy to share the prompt if you guys want it...but I made this with perplexity_ai's Computer.

here is the prompt I used on perplexity_ai max (Computer)...feel free to mess around with the weightings, etc.

PROMPT:

Build “Should I Be Trading?” — Bloomberg Terminal-Style Market Dashboard

Build a live, auto-refreshing Bloomberg Terminal-style web dashboard called “Should I Be Trading?” that evaluates the current stock market environment and outputs a clear, actionable trading decision for swing traders.

Core Output

The system must display:

1. Decision: YES / CAUTION / NO

2. Market Quality Score: 0–100%

3. Execution Window Score: 0–100% (separate)

4. Plain-English Summary: concise explanation of the environment

Data Inputs (Live or Latest Available)

Volatility / Risk

- $Cboe Volatility Index(VIX)$ level, trend (5d slope), and 1-year percentile

- $VIX Volatility Index(VVIX)$ (if available)

- Put/Call ratio (estimate if needed from VIX regime)

Trend & Structure

- S&P 500 ( $SPDR S&P 500 ETF Trust(SPY)$ ) vs 20 / 50 / 200-day moving averages

- $Invesco QQQ(QQQ)$ vs 50-day moving average

- SPY 14-day RSI

- Market regime classification: uptrend / downtrend / chop

Breadth

- % of stocks above 20d / 50d / 200d moving averages

- NYSE Advance/Decline line + daily ratio

- Nasdaq new highs vs new lows

- McClellan Oscillator (optional if available)

Momentum / Participation

- All 11 S&P sector ETFs: XLK, XLF, XLE, XLV, XLI, XLY, XLP, XLU, XLB, XLRE, XLC

- Top 3 vs bottom 3 sector performance (relative strength spread)

- % of stocks making higher highs

Macro / Liquidity

- 10-Year Treasury yield (level + short-term trend)

- Dollar Index (DXY trend)

- Fed stance (derived or labeled: hawkish / neutral / dovish)

- FOMC calendar (flag if event within 72 hours or same day)

- Optional: CPI / Jobs flags

Scoring System

Calculate category scores (0–100):

- Volatility: 25%

- Momentum: 25%

- Trend: 20%

- Breadth: 20%

- Macro/Liquidity: 10%

Then compute:

Market Quality Score = weighted average

Decision Logic

- 80–100 → YES

Full position sizing, press risk

- 60–79 → CAUTION

Half size, A+ setups only

- <60 → NO

Avoid trading, preserve capital

Execution Window Score (Critical Layer)

Separate score that evaluates whether setups are actually working:

- Are breakouts holding above pivot levels?

- Are leading stocks maintaining gains after breakout?

- Are pullbacks being bought quickly?

- Is there multi-day follow-through?

Score 0–100 and factor into final explanation (but NOT the main score weighting).

UI / UX Requirements (Bloomberg Terminal Style)

Visual Style

- Dark blue/black background

- Monospace font

- Green / red / amber indicators

- Minimal, dense, high-signal layout

Layout

Top Bar

- Scrolling ticker (SPY, QQQ, VIX, DXY, TNX, sectors)

- Status indicator: LIVE / UPDATING

- Last updated timestamp (“updated 12s ago”)

- Manual refresh button

Hero Panel

- Large “Should I Trade?” decision badge (YES / CAUTION / NO)

- Circular score visualization (0–100%)

- Subtext: “Market Quality Score”

Core Panels (Grid)

Each panel includes:

- Current value

- Direction (↑ ↓ →)

- Interpretation (healthy / weakening / risk-off)

Panels:

1. Volatility

2. Trend

3. Breadth

4. Momentum

5. Macro

Sector Heatmap

- Horizontal bar visualization of 11 sector ETFs

- Highlight leaders vs laggards

Scoring Breakdown Panel

- Show weight + score per category

- Visual contribution to total score

Alert Banner

- Display when FOMC / CPI / major macro event is imminent

Terminal Analysis (AI Layer)

Generate a short explanation like:

“This is a strong trend environment with expanding breadth and moderate volatility. Sector leadership is concentrated in technology and industrials. Favor selective swing trades with disciplined risk.”

Mode Toggle

- Swing Trading Mode

- Day Trading Mode (adjust thresholds slightly tighter and faster)

Technical Requirements

- Auto-refresh every 45 seconds

- Server-side cache (30 seconds) to reduce API load

- Loading skeleton states while fetching

- Error handling for missing data

- Modular architecture (easy to swap APIs)

Output Requirements

Return:

1. Full frontend layout (React preferred, Tailwind optional)

2. Backend/data aggregation logic (Node or Python)

3. Clear scoring formulas (editable)

4. Example output using current/latest market data

5. API recommendations (free + paid)

Success Criteria

- Clean, fast, high-signal UI

- Accurate regime detection

- Simple, trustworthy YES / NO output

- Feels like a personal risk manager, not just a data dashboard


For SG users only, Welcome to open a CBA today and enjoy access to a trading limit of up to SGD 20,000 with unlimited trading on SG, HK, and US stocks, as well as ETFs.

🎉Cash Boost Account Now Supports 35,000+ Stocks & ETFs – Greater Flexibility Now

Find out more here.

Complete your first Cash Boost Account trade with a trade amount of ≥ SGD1000* to get SGD 688 stock vouchers*! The trade can be executed using any payment type available under the Cash Boost Account: Cash, CPF, SRS, or CDP.

Click to access the activity

Other helpful links:

Disclaimer: Investing carries risk. This is not financial advice. The above content should not be regarded as an offer, recommendation, or solicitation on acquiring or disposing of any financial products, any associated discussions, comments, or posts by author or other users should not be considered as such either. It is solely for general information purpose only, which does not consider your own investment objectives, financial situations or needs. TTM assumes no responsibility or warranty for the accuracy and completeness of the information, investors should do their own research and may seek professional advice before investing.

Comments

We need your insight to fill this gap
Leave a comment