相同的背景颜色 n 条向后

Same background color n bars backwards

我想为 Traingview 图表的背景着色,例如红色,n 条倒退。我该怎么做?

尝试次数(不考虑时间):

study(title="DbgRed", shorttitle="", overlay=true)
bgcolor(color.red, transp=75)

我无法在用户手册中或通过 Google 搜索找到答案。

如何为背景着色并添加 n 条的着色。

您可以使用 show_last 参数将 bgcolor 尾随 x 条。

//@version=4
study(title="DbgRed", shorttitle="", overlay=true)
bgcolor(color.red, transp=75, show_last = 25)

干杯,祝你好运