OPEN-SOURCE SCRIPT

Contador de SL y TP Manual

//version=5
indicator("Contador de SL y TP Manual", overlay=true)

// Inputs para ajustar manualmente los contadores
slCount = input.int(1, title="Contador de SL", minval=1, maxval=50)
tpCount = input.int(1, title="Contador de TP", minval=1, maxval=50)

// Crear una tabla para mostrar los contadores
var table contadorTable = table.new(position.top_center, 2, 1, border_width=1, frame_color=color.black, frame_width=1)

// Actualizar la tabla con los valores de SL y TP
table.cell(contadorTable, 0, 0, "SL: " + str.tostring(slCount), text_color=color.red)
table.cell(contadorTable, 1, 0, "TP: " + str.tostring(tpCount), text_color=color.green)
Advance/Decline RatioCandlestick analysisPine utilities

Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in publication is governed by House rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Disclaimer