File: tradingview.actual

package info (click to toggle)
golang-github-alecthomas-chroma-v2 2.12.0-1~bpo12%2B1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm-backports
  • size: 9,172 kB
  • sloc: xml: 38,564; python: 422; javascript: 357; sh: 37; makefile: 36
file content (14 lines) | stat: -rw-r--r-- 392 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
//@version=3
study(title="Chroma example script", overlay=true, precision=3)

emaLen = input(title="EMA Length", type=integer, defval=10)
emaVal = ema(close, emaLen)

plot(series=emaVal, style=circles, offset=2, linewidth=3)

// Colour background
bgcolor(color=close > open ? orange :
     close != high[1] ? purple :
     na, transp=80)

// Comment as last line should be recognised properly