Skip to content

Examples ​

Every example here is a script you can run: the strategies are in the chart's picker under Strategies, and the indicators are the chart's built-in indicators. The source on each page is the exact file the platform runs.

Strategies ​

StrategyResolutionWhat it does
Block scalper1BBlock-level scalper for the 1B (bar per block) mode
Bollinger breakout15mBuys a volume-confirmed close above the upper Bollinger band, exits on an ATR trail or the basis
DCA with liquidity guard1hDollar-cost averages into the pool only while liquidity is deep
EMA cross on alpha15mBuys a fast/slow EMA cross up while the pool is deep enough, exits on the cross down
Moving-price discount15mBuys when the pool trades below the protocol's moving price
Moving-price momentum15mTrades momentum in the moving price
Regime switch1hSwitches between mean-reversion and trend rules by volatility (ATR / price)
RSI mean reversion15mBuys oversold RSI with a price limit, sells when RSI recovers
Session DCA1hScheduled buys sized to the pool's capacity
Supertrend follow1hLong while Supertrend points up, flat while it points down
Whale flow15mReacts to large pool trades (onTrade)

Indicator examples ​

IndicatorWhat it shows
RSI + pool depth

Built-in indicators ​

Moving averages ​

IndicatorWhat it shows
Arnaud Legoux Moving AverageArnaud Legoux: Gaussian-weighted window with an adjustable centre
Double EMADouble EMA: 2 x EMA minus EMA of EMA, less lag
Moving Average ExponentialExponentially weighted mean, reacts faster than SMA
Guppy Multiple Moving AverageSix short and six long EMAs: trader and investor groups
Hull Moving AverageHull: WMA of 2 x WMA(n/2) minus WMA(n), fast and smooth
Least Squares Moving AverageLeast squares line through the last N closes, at its end
MA CrossShort and long SMA with a mark where they cross
Moving Average RibbonFour moving averages of one type, 20 to 200 bars
McGinley DynamicMoving average that speeds up and slows down with the market
Moving Average SimpleArithmetic mean of the last N closes
Smoothed Moving AverageSmoothed (Wilder) moving average, the RMA used by RSI and ATR
Triple EMATriple EMA: three nested EMAs combined to cut lag further
Volume Weighted Moving AverageMean weighted by each bar's alpha volume
Moving Average WeightedLinearly weighted mean of the last N values

Bands & channels ​

IndicatorWhat it shows
Bollinger BandsSMA basis with standard-deviation bands
Bollinger Bands %BWhere price sits within the Bollinger Bands, 0 = lower, 1 = upper
Bollinger BandWidthBollinger band width relative to the basis, with expansion and contraction marks
Donchian ChannelsHighest high and lowest low of N bars
EnvelopeSMA with fixed percentage bands
Keltner ChannelsEMA basis with ATR bands
Moving Average ChannelSMA of the highs and SMA of the lows as a channel
Standard Error BandsRegression line with standard-error bands, smoothed

Trend ​

IndicatorWhat it shows
Average Directional IndexTrend strength (Wilder), 0 to 100
Williams AlligatorThree smoothed averages shifted forward: jaw, teeth and lips
AroonBars since the N-bar high and low, as 0 to 100
Candlestick PatternsMarks 19 candlestick patterns: hammers, engulfing, harami, stars, soldiers, tweezers, doji
Choppiness IndexChoppiness: high when the market ranges, low when it trends
Chop ZoneEMA slope as coloured columns, from trending to choppy
Chande Kroll StopStops from the N-bar extreme minus ATR, for longs and shorts
Directional Movement Index+DI and -DI directional movement with ADX trend strength
Ichimoku CloudConversion and base lines, a lagging span and the cloud projected 26 bars ahead
Parabolic SARParabolic stop and reverse: trailing dots that flip with the trend
SupertrendATR trailing line that flips with the trend
Trend Strength IndexCorrelation of price with time, -1 to 1
Volatility StopATR trailing stop that flips with the close
Vortex IndicatorVI+ and VI- trend lines from upward and downward movement
VWAPVolume weighted average price, anchored to the UTC day

Oscillators ​

IndicatorWhat it shows
Accelerator OscillatorAwesome Oscillator minus its 5-bar SMA, coloured by direction
Average Day RangeAverage high-to-low range over N bars
Awesome Oscillator5-bar minus 34-bar SMA of the bar midpoint
Average True RangeAverage true range (volatility)
Bull Bear PowerHigh and low against an EMA: bull minus bear pressure
Balance of PowerClose minus open over the bar range, -1 to 1
Commodity Channel IndexDeviation from the mean in units of mean deviation
Chande Momentum OscillatorChande momentum: sum of rises minus falls over their total
Connors RSIAverage of a short RSI, a streak RSI and a 100-bar percent rank
Coppock CurveWMA of two rates of change, a long-term momentum gauge
Detrended Price OscillatorClose minus a lagged SMA, to show cycles without the trend
Fisher TransformGaussian transform of price within its range, with a trigger line
Historical VolatilityAnnualised standard deviation of log returns, in percent
Know Sure ThingKnow Sure Thing: weighted sum of four smoothed rates of change
Linear Regression SlopeBar-to-bar change of the least-squares line
MACDEMA difference, signal line and histogram
Majority RuleShare of bars that closed up over the last N, in percent
Mass IndexSum of the EMA range ratio, flags reversals when the range widens
Money Flow IndexVolume weighted RSI on the typical price
MomentumPrice change over N bars
Price OscillatorPercentage difference between a short and a long moving average
Rank Correlation IndexSpearman rank correlation of price and time, -100 to 100
Rate Of ChangePercent change over N bars
Relative Strength IndexRelative strength index with 70/30 bands
Relative Vigor IndexRelative vigor: close minus open against the range, with a signal
Relative Volatility IndexRSI computed on standard deviation instead of price change
SMI Ergodic IndicatorTrue strength index on fast settings with a signal line
SMI Ergodic OscillatorSMI Ergodic minus its signal, as a histogram
Standard DeviationStandard deviation of the source over N bars
StochasticClose within the N-bar range, %K and %D
Stochastic RSIStochastic applied to RSI, with K and D lines
TRIXRate of change of a triple-smoothed EMA of the log price
True Strength IndexDouble-smoothed momentum with a signal line
Ulcer IndexDepth and duration of drawdowns from the N-bar high
Ultimate OscillatorWeighted buying pressure over three lookbacks, 0 to 100
Williams %RClose relative to the N-bar high, -100 to 0
Woodies CCICCI 14 histogram with a fast turbo CCI

Volume ​

IndicatorWhat it shows
Accumulation/DistributionRunning total of volume weighted by the close within the range
Chaikin OscillatorFast minus slow EMA of accumulation/distribution
Chaikin Money FlowAccumulation over N bars divided by volume, -1 to 1
Elder Force IndexEMA of the price change times volume
Ease of MovementPrice movement per unit of volume, smoothed
Net Stake FlowTAO turnover signed by bar direction: net stake flow
Klinger OscillatorEMA difference of volume signed by the typical price
Net VolumeBar volume signed by the close-to-close move
On Balance VolumeCumulative volume signed by the close-to-close move
Price Volume TrendRunning total of volume weighted by the percent change
Session Volume ProfileA volume profile for every day or week, with value area and POC
Volume OscillatorShort minus long volume EMA, in percent
VolumeAlpha or TAO volume coloured by bar direction, with MA
Visible Range Volume ProfileVolume at each price over the bars on screen, with value area and POC

Chain ​

IndicatorWhat it shows
Moving Price (chain)The protocol's moving price used for emissions

Support & resistance ​

IndicatorWhat it shows
Auto Fib RetracementFib retracement drawn automatically over the latest swing
Auto Fib ExtensionTrend-based fib extension from the last two swings
Williams FractalsMarks highs and lows that stand above or below their neighbours
52 Week High/LowHighest high and lowest low of the last 52 weeks
Linear Regression ChannelRegression line through the last N bars with deviation bands
Pivot Points StandardDaily or weekly pivot levels from the previous period, five formulas
Pivot Points High LowLabels at swing highs and lows confirmed N bars later
Zig ZagJoins swing highs and lows that reverse by more than a set percentage

AlphaScript language v0.1 · runtime 0.2.0