Functions
hline()
Draws a horizontal line at a fixed price. The price is input-form, so it cannot follow the data — a line that has to move is a plot, not a level. `hline` returns a value, which is what lets you pass two levels to `fill`.
Syntax
hline(input float price, const string title, input color color, input int linewidth, input hlineStyle style) → series hline
Arguments
price required input float The price the line sits at. Required, and input-form, so it is settled before the script runs. title const string The line's name. Const-form. color input color The line's colour. Input-form here, not series: a level's colour is fixed for the run of the script. linewidth input int How wide the line is drawn. Input-form. style input hlineStyle Which member of the `hlineStyle` set to draw: `solid`, `dashed` or `dotted`. Return Type
series hline Example
indicator("Horizontal Line Example", overlay=true)
// Draw a horizontal line at 4000
hline(4000, "Support Level", color=color.blue, linewidth=2, style=hlineStyle.dashed)