LIVE - AI Trading Bot - Bitcoin + Ethereum - 5 Minute Chart
I added a BUY and SELL parameter to the LONG and SHORT from the previous version.
BUY occurs when the CCI rises above 0.00
SELL occurs when the CCI drops below 0.00
LONG occurs when the CCI is below -100 and then rises above -100
SHORT occurs when the CCI drops below -100
Going LONG reverses a SHORT position
Going SHORT reverses a LONG position
A LONG followed with a BUY = 2X LONG
2X LONG positons are closed with a SELL
Here is the code for you to use and modify:
//@version=5
indicator("CCI.36.LONG.BUY.SELL.SHORT", overlay=true)
// Calculate CCI
length = input.int(36, title="CCI Length")
cci_value = ta.cci(close, length)
// Define -100 line buy and sell conditions
buy_signal_neg100 = ta.crossover(cci_value, -100)
sell_signal_neg100 = ta.crossunder(cci_value, -100)
// Define zero line buy and sell conditions
buy_signal_zero = ta.crossover(cci_value, 0)
sell_signal_zero = ta.crossunder(cci_value, 0)
// Plot buy and sell signals on CCI with text labels
plotshape(series=buy_signal_neg100, title="Buy Signal (Below -100)", location=location.belowbar, color=color.green, style=shape.triangleup, size=size.small, text="LONG", textcolor=color.green, offset=0)
plotshape(series=sell_signal_neg100, title="Sell Signal (Above -100)", location=location.abovebar, color=color.red, style=shape.triangledown, size=size.small, text="SHORT", textcolor=color.red, offset=0)
plotshape(series=buy_signal_zero, title="Buy Signal (Crossover Zero)", location=location.belowbar, color=color.blue, style=shape.triangleup, size=size.small, text="BUY", textcolor=color.blue, offset=0)
plotshape(series=sell_signal_zero, title="Sell Signal (Crossunder Zero)", location=location.abovebar, color=color.orange, style=shape.triangledown, size=size.small, text="SELL", textcolor=color.orange, offset=0)
-
LIVE
Fresh and Fit
3 hours agoAfter Hours w/ SNEAKO, SonnyFaz & Elijah Schaffer
30,286 watching -
2:04:50
Fresh and Fit
9 hours agoElijah Schaffer Meets Fresh&Fit
95.7K70 -
2:03:29
The Anthony Rogers Show
14 hours agoEpisode 305 - Sloan Bella
26.8K11 -
1:41:08
Glenn Greenwald
11 hours agoRussia-Ukraine War Escalates Amid Nuclear Threats, Israel Was Motive Behind TikTok Ban; PLUS: Batya Ungar-Sargon on New Book | SYSTEM UPDATE #267
77.5K110 -
1:33:30
Donald Trump Jr.
12 hours agoThe Process is the Punishment: Evidence Tampering, Lies, and the Boxes Hoax, Live with Reporter Julie Kelly | TRIGGERED Ep.134
131K188 -
2:27:12
WeAreChange
7 hours agoMiddle East Peace Process Breaks Down in the 23rd Hour: Brace for Impact
56.8K35 -
1:01:10
The StoneZONE with Roger Stone
8 hours agoHas an Iranian Spy Ring Permeated the US Gov? Author & Journalist Lee Smith Enters The StoneZONE!
39.4K7 -
2:01:58
Film Threat
13 hours agoVERSUS: THE DEATH OF STAR WARS: REVENGE OF THE SIXTH | Film Threat Versus
52.3K7 -
1:36:32
The Quartering
9 hours agoTrump Threatened With Jail, Legal Ramifications Of Campus Commies & More With Ron Coleman
77.6K62 -
1:37:32
2 MIKES LIVE
15 hours ago#62 2ML Join us to breakdown all the news worth mentioning!
39.5K15