Skip to main content

rgb

Syntax Format​

rgb(r, g, b)

Overview​

The rgb function provides the color customization to the indicator's plot. You can use this function to set specific colors in a script.

Parameters​

ParameterTypePurpose
rintegerThe red component of the color in the range of [0,255]
gintegerThe green component of the color in the range of [0,255]
bintegerThe blue component of the color in the range of [0,255]

Returns: color.

Example​

plot_color = rgb(0, 255, 0) -- green color as a result