Functions
label.set_xy()
Sets a label's x and y coordinates.
Syntax
label.set_xy(series label id, series int x, series float y) → void
Arguments
id required series label Drawing object to modify or query. x required series int X-coordinate (bar index or time, depending on xloc). y required series float Y-coordinate (price). Return Type
void Example
//@lipi=2
indicator("label.set_xy Example", overlay=true)
if barstate.islast {
lb = label.new(bar_index, high, text="Hi", color=color.green)
label.set_xy(lb, bar_index, close)
}