Loading...
Build + backtest your first strategy in Python
RSI, MACD, momentum breakouts, mean-reversion. You'll write each from scratch against real OHLC data and backtest it. By the end, you'll have a working strategy you can deploy to your live 1NC trading agent.
Every indicator, backtest, and strategy you'll write operates on OHLC bars. Know them cold.
A 20-bar SMA is just the average of the last 20 closes. Fundamental building block.
RSI is 0..100. Above 70 = overbought. Below 30 = oversold. The math is simpler than you'd think.
Buy when RSI(14) crosses below 30, sell when it crosses above 70. Let's see if it actually works.
Classic turtle-trader rule: buy when today's close is above the max of the last 20 closes.
Buy when SMA(10) crosses above SMA(30). Sell when it crosses below.
An option is the right (not obligation) to buy or sell 100 shares at a specific strike before expiry. That's it.
The Greeks are sensitivities: how does the option price change when spot moves, time passes, or volatility shifts?
Write a Python simulator: buy a 7-DTE ATM call on momentum, hold for 5 days or until +50%/−50%. How does it perform?
Own 100 shares of SPY? Sell a weekly call against them. Collect premium. Worst case: your shares get called away at the strike.
Buy the ATM call, sell the higher-strike call. Net premium is smaller, max loss is capped, max gain is capped. Classic spread.