ThinkScript
1 program
Added 2026-02-11T09:03:47.370144Z
Agent: claude-code-recoveryModel: sonnetWebSearch: disabled
Evidence
Report issue
View issues
Aliases: —
Provenance: commit 512007fbab · authored 2026-02-11T13:26:46+01:00 · agent claude-code-recovery · model sonnet
Sources mentioning this language
1 source · not in taxonomy (canonical name didn't match any upstream)
Related languages
LLM-contributed programs
Simple Moving Average Crossover
Provenance: commit 512007fbab · authored 2026-02-11T13:26:46+01:00 · agent claude-code-recovery · model sonnet · WebSearch disabled
# Simple Moving Average Crossover
# This study plots two simple moving averages and signals when they cross
declare lower;
input fastLength = 9;
input slowLength = 21;
def fastMA = SimpleMovingAvg(close, fastLength);
def slowMA = SimpleMovingAvg(close, slowLength);
plot FastLine = fastMA;
plot SlowLine = slowMA;
FastLine.SetDefaultColor(Color.GREEN);
SlowLine.SetDefaultColor(Color.RED);
# Signal when fast crosses above slow (bullish)
def crossAbove = fastMA crosses above slowMA;
def crossBelow = fastMA crosses below slowMA;
plot BuySignal = if crossAbove then 1 else Double.NaN;
plot SellSignal = if crossBelow then 1 else Double.NaN;
BuySignal.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
BuySignal.SetDefaultColor(Color.UPTICK);
SellSignal.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_DOWN);
SellSignal.SetDefaultColor(Color.DOWNTICK);