Advertisement
Guest User

Untitled

a guest
Mar 30th, 2020
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.81 KB | None | 0 0
  1. study(title="Belis-WMA X Cloud 1.0", shorttitle="Belis-WMA X Cloud 1.0", overlay=true)
  2.  
  3. len = (input(title = 'Short WMA', type=input.integer, minval=1, maxval=1000, defval=12))
  4. len2 = (input(title = 'Long WMA', type=input.integer, minval=1, maxval=1000, defval=26))
  5.  
  6.  
  7.  
  8. // Allazontas sto apo katw to 'D' me 'W' or 'M' allazeis to reference time frame.
  9.  
  10. DailyWmaShort =security(syminfo.tickerid, 'D', wma(close, len), lookahead=true)
  11. DailyWmaLong =security(syminfo.tickerid, 'D', wma(close, len2), lookahead = true)
  12.  
  13. spanColor = DailyWmaShort>=DailyWmaLong ? #e34bea : #2206d3
  14.  
  15. p1 = plot(DailyWmaShort, title="Daily WMA Short", linewidth=1, color=#e34bea, transp=0)
  16. p2 = plot(DailyWmaLong, title="Daily WMA Long", linewidth=1, color=#2206d3, transp=0)
  17.  
  18.  
  19. fill(p1, p2, color=spanColor, transp=65, title="Fill")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement