UCS_S_Steve Primo - Strategy 4 - Version 2

For those who are interested with this strategy, Here is a better version.
Remove from Favorite Scripts Add to Favorite Scripts
// Created by UCSgears
// Includes options to confirm with Pet-d

study(shorttitle="SP-S#4", title = "Steve Primo - Strategy #4", overlay = true, precision = 2)

basisma = sma(close,50)
petd = ema(close,15)

usepetd = input(true, title = "PET-D Confirmation Required")

trendup = usepetd == 1 ? close > basisma and close > petd : close > basisma
trenddn = usepetd == 1 ? close < basisma and close < petd : close < basisma

// PET-D

petdcolor = close > petd ? green : red
barcolor (petdcolor)

// Pullback & Bounce Criteria
lowest = lowest(low,(5))
highest = highest(high,(5))
pullback = (low == lowest) or (low[1] == lowest[1]) ? 1 : 0
bounce = (high == highest) or (high[1] == highest[1]) ? 1 : 0

plot (lowest, color = green, linewidth = 1, title = "Lower Band")
plot (highest, color = red, linewidth = 1, title = "Upper Band")
plot (basisma, color = black, linewidth = 3, title = "Trend - Long Term")
plot (petd, color = blue, linewidth = 1, title = "Trend - Short Term")

// 25% Close 
range = high - low
rbrng = abs(open-close)
// Long Setup
longcandle = close > low+range*.75 ? 1:0
// Short Setup
shortcandle = close < low+range*.25 ? 1:0

setuplong = trendup == 1 and pullback == 1 and longcandle == 1 ? 1:0
setupshort = trenddn == 1 and bounce == 1 and shortcandle == 1 ? 1:0

//setuplong = setuplonggeneral == 1 and setuplonggeneral[1] == 0 ? 1:0
//setupshort = setupshortgeneral == 1 and setupshortgeneral[1] == 0 ? 1:0

bcl = rbrng > (rma(tr,5)*1.1) ? blue : green
bcs = rbrng > (rma(tr,5)*1.1) ? blue : red

plotchar(setuplong, title="Long Setup Bar", char='⇑', location=location.belowbar, color=bcl, transp=0, text="Strategy #4 Long")
plotchar(setupshort, title="Short Setup Bar", char='⇓', location=location.abovebar, color=bcs, transp=0, text="Strategy #4 Short")

//Trade Trigger
tiggerlongcandle = (setuplong[1] == 1) and (high > high[1]) ? 1 : 0
tiggershortcandle = (setupshort[1] == 1) and (low < low[1]) ? 1 : 0
plotshape(tiggerlongcandle ? tiggerlongcandle : na, title="Triggered Long",style=shape.triangleup, location=location.belowbar, color=green, transp=0, offset=0)
plotshape(tiggershortcandle ? tiggershortcandle : na, title="Triggered Short",style=shape.triangledown, location=location.abovebar, color=red, transp=0, offset=0)

// Trade Target Signal

tarup = (tiggerlongcandle==1 and setuplong[1] == 1) ? high[1]+range[1] : na
plotshape(tarup, style = shape.circle, location = location.absolute, title = "Target Long", color = white)

tardn = (tiggershortcandle==1 and setupshort[1] == 1) ? low[1]-range[1] : na
plotshape(tardn, style = shape.circle, location = location.absolute, title = "Target Short", color = white)
I agree and appreciate you posting it.
Does this "Strategy #4" repaint the chart with "Long" or "Short" plotchar after 2-4 bars or do these signals appear right with the daily bar (the close of it)? If it does not repaint it seems to be quite a good strategy, which my quick test on the DAX showed. Thank you for improving your code.

ChartArt ChartArt
As always, staying with the overall trend is the more successful strategy, Shorting Bitcoin worked with this strategy three times. But going long failed very hard two times and worked only once in recent weeks. So this is a reminder to never follow an indicator blindly:

Well, Steve climbs the risk and reward ratio to be 1:1.
sanaga ChartArt
Good Point ChartArt. Steve Primo suggests just that.
It does not repaint.
sanaga ucsgears
UCS, thanks again. Steve P. uses the range (measured from the start of the trend) as Stop. He also uses some target profit points. Are you considering incorporating these in the next release?
Assuming the black curve is the MA. Aaccording to Steve Primo, you should not short when market or price is above the Moving Average curve. If you apply this rule, you will miss out of short opportunities as seen above (First Red candle around April 22nd), right? Any way around this?
Missing opportunity is / shouldn't be a concern. Its all theoretical odds you have to play. For example,
Scanning for a group of tickers where this works is up to you. Otherwise,
Just to be clear, and I know I already asked, could anyone explain this

lowest = lowest(low,(5))
highest = highest(high,(5))
pullback = (low == lowest) or (low == lowest) ? 1 : 0
bounce = (high == highest) or (high == highest) ? 1 : 0

in lamens' terms
ucsgears PRO gottimhimmel
Watch Steve's video. His criteria is the code.
Can you tell me how to load this in TOS?
meleysr.1 meleysr.1
When I copy the code and paste it in the editor, I get an invalid statement:// at 1:1. Can someone point me in the right direction?
ucsgears PRO meleysr.1
replace the // with #.

The code needs to be modified a bit before it can be used at tos
meleysr.1 ucsgears
OK thanks
ddemann ucsgears
@ucsgears, Is it possible for you to create a TOS version of the script. I would be willing to pay for the conversion. Thank you. Drew. email: demann@me.com
@ddemann, Sorry dude, Copyright issues. I don't want to expose myself.
ddemann ucsgears
@ucsgears, I think you mis-understood. I am asking if you could convert your own script shown above to TOS. You have already published your own script.
Hi ucsgears,

how can I use this indicator in MT4 ( Can you please Instruct me how I can Load this up in MT4 )
Thank you for your Precious Time and Hard work ucsgears. ( also do you sell any other indicators )? thanks man
I cannot give the MT4 code,Steve Primo is directly selling, Just to avoid any legal litigation, I would avoid that scenario...... Any the concept is here, feel free to write the code.... Sorry.
Sorry I am not a programmer.... Is it possible to get the executable for this indicator? mytymedave@gmail.com
DavidMiller1a DavidMiller1a
Sorry.... Just saw your response above after I sent this
United States
United Kingdom
Home Stock Screener Forex Signal Finder Economic Calendar How It Works Chart Features House Rules Moderators For the WEB Widgets Stock Charting Library Priority Support Feature Request Blog & News FAQ Help & Wiki Twitter
Private Messages Chat Ideas Published Followers Following Priority Support Public Profile Profile Settings Account and Billing Sign Out