Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // 8888888888 8888888b. 8888888888 8888888888 d8888 888 .d8888b. .d88888b. As you
- // 888 888 Y88b 888 888 d88888 888 d88P Y88b d88P" "Y88b Can see
- // 888 888 888 888 888 d88P888 888 888 888 888 888 Are all
- // 8888888 888 d88P 8888888 8888888 d88P 888 888 888 888 888 .d8888b Basic free
- // 888 8888888P" 888 888 d88P 888 888 888 88888 888 888 88K tradingview
- // 888 888 T88b 888 888 d88P 888 888 888 888 888 888 "Y8888b. indicators
- // 888 888 T88b 888 888 d8888888888 888 Y88b d88P Y88b. .d88P X88 repackaged
- // 888 888 T88b 8888888888 8888888888 d88P 888 88888888 "Y8888P88 "Y88888P" 88888P' into one
- //
- // FAQ
- //
- // Why?
- // I want you to see what you are willing to pay hundereds of dollars a month
- // Has the code been leaked/hacked?
- // No, this code has been created only using common sense and public information from the internet
- // What's the accuracy I can expect from this version of the indicator?
- // I'd say it's about 90% the same as the one you would pay
- // The indicator needs to be updated?
- // Write me a private message on TradingView (Nick42_for_win)
- // Can I suggest an indicator to get a FREE ALGOs version?
- // Write me a private message on TradingView (Nick42_for_win)
- // Do you get any monetary return from this project?
- // Nope, 0$
- // Enjoy ;)
- //@version=5
- indicator("FREE ALGOs [AI Signals Oscillator]", overlay=false, precision=0)
- //------------------ AI Signals | https://www.getaisignals.com ---------------//
- // Get user input
- len = input.int(9, "Length", 1)
- style = input.string("Columns", "Style", ["Columns", "Histogram", "Matrix"])
- // Get Components
- top = ta.highest(high, len)
- bot = ta.lowest(low, len)
- osc = ta.mom(ta.sma(ta.ema(close, len), len), len)
- osc2 = osc * 0.825
- osc3 = osc * 0.650
- osc4 = osc * 0.490
- osc5 = osc * 0.345
- osc6 = osc * 0.215
- osc7 = osc * 0.100
- osc8 = osc * 0.010
- oscRis = osc > osc[1]
- oscFal = osc < osc[1]
- oscA0 = osc > 0
- oscB0 = osc < 0
- oscTop = oscFal and oscRis[1]
- oscBot = oscRis and oscFal[1]
- bullR = oscB0 and oscBot and osc > ta.valuewhen(oscB0 and oscBot, osc, 1) and bot < ta.valuewhen(oscB0 and oscBot, bot, 1)
- bearR = oscA0 and oscTop and osc < ta.valuewhen(oscA0 and oscTop, osc, 1) and top > ta.valuewhen(oscA0 and oscTop, top, 1)
- bullH = oscB0 and oscBot and osc < ta.valuewhen(oscB0 and oscBot, osc, 1) and bot > ta.valuewhen(oscB0 and oscBot, bot, 1)
- bearH = oscA0 and oscTop and osc > ta.valuewhen(oscA0 and oscTop, osc, 1) and top < ta.valuewhen(oscA0 and oscTop, top, 1)
- // Colors
- green = #00DD00, green50 = color.new(green, 50), green20 = color.new(green, 80)
- red = #DD0000, red50 = color.new(red, 50), red20 = color.new(red, 80)
- colorOsc = oscA0 ? (oscRis ? green50 : green20) : (oscFal ? red50 : red20)
- // Plots
- plot(osc, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(osc2, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(osc3, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(osc4, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(osc5, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(osc6, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(osc7, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(osc8, "", colorOsc, 1, style == "Columns" ? plot.style_columns : style == "Histogram" ? plot.style_histogram : plot.style_cross, editable=false)
- plot(oscB0 and oscBot ? osc : na, "", bullR or bullH ? red20 : na, 2, editable=false)
- plot(oscA0 and oscTop ? osc : na, "", bearR or bearH ? green20 : na, 2, editable=false)
- plotshape(bullR ? osc : na, "Regular Bullish", shape.labelup, location.absolute, green50, 0, "RB", color.white, false, size.tiny)
- plotshape(bearR ? osc : na, "Regular Bearish", shape.labeldown, location.absolute, red50, 0, "RB", color.white, false, size.tiny)
- plotshape(bullH ? osc : na, "Hidden Bullish", shape.labelup, location.absolute, green20, 0, "HB", color.white, false, size.tiny)
- plotshape(bearH ? osc : na, "Hidden Bearish", shape.labeldown, location.absolute, red20, 0, "HB", color.white, false, size.tiny)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement