*
tgp API Reference
tgp.ohlcv('AAPL', '1d') → DataFrame (date,open,high,low,close,volume)tgp.price('AAPL') → float (latest close)tgp.fundamentals('AAPL') → dict (PE, market_cap, ...)tgp.news('AAPL', min_score=80) → scored news listtgp.news_score('AAPL', 80, 10) → bullish/bearish summarytgp.ohlcv('^VIX') → VIX regime datatgp.event → dict (trigger event data)Indicators
tgp.sma(series, period) → Simple MAtgp.ema(series, period) → Exponential MAtgp.rsi(series, 14) → RSI (0-100)tgp.macd(series) → (line, signal, hist)tgp.bbands(series, 20) → (upper, mid, lower)tgp.atr(high, low, close, 14) → ATRtgp.stoch(high, low, close) → (%K, %D)tgp.vwap(high, low, close, vol) → VWAPSignals
tgp.crossover(a, b) → bool Series (a crosses above b)tgp.crossunder(a, b) → bool Series (a crosses below b)tgp.signal(positions) — Required! 1=long, -1=short, 0=flat. Must match data length.
Backtest: outputs metrics. Live: outputs last signal for automation chain.
Premium strategy code is hidden on your plan. You can run a server-side backtest, but code editing and deployment require a paid tier.
Upgrade
Preset backtests are open. Log in to edit code, save files, or deploy automations.
Log in
Select a workflow from the left, or backtest a strategy and create a paper workflow.
Pinned Sample Event
Loading workflow graph...