This is a Pine Script implementation of “Capitalize AI: Volume Spike Strategy" by Bitcoin Trading Challenge (copied with permission).
Original Capital AI formula :
If BTC/USD 1 minute volume > BTC/USD average volume in 20-1m bar by at least 500% and if BTC/USD is below the MA(5,1m,close) of BTC/USD then buy 10,000 USD WORTH of BTC/USD
Tested on XBTUSD 1 minute.
Original strategy is buy-only. Option for sells was added (enable in settings).
First published script -- comments/feedback appreciated