OPEN-SOURCE SCRIPT
Atualizado Rebalance Oscillator

Rebalancing is a common strategy to reduce risk and achieve a constant portfolio ratio between two tokens. It shifts between two values in order to keep a static ratio between them as their value oscillates.
However what is less known about rebalancing is that it provides a way to remove the noise from a signal, effectively showing us the points where to buy and to sell.
This works best in highly volatile tickers, between two tokens that are not correlated and show a high std deviation between them (i.e. XTZUSD is a better signal for this than XTZBTC).
The buying bars are marked in blue, and the selling bars are marked in red, in a similar fashion to Trading View strategy orders.
However what is less known about rebalancing is that it provides a way to remove the noise from a signal, effectively showing us the points where to buy and to sell.
This works best in highly volatile tickers, between two tokens that are not correlated and show a high std deviation between them (i.e. XTZUSD is a better signal for this than XTZBTC).
The buying bars are marked in blue, and the selling bars are marked in red, in a similar fashion to Trading View strategy orders.
Notas de Lançamento
In this revision the chart is inverted (Top represent sales - red values; Bottom represent buys - blue values).The code is simpler and uses two libraries.
Script de código aberto
No verdadeiro espirito do TradingView, o autor desse script o publicou como código aberto, para que os traders possam entendê-lo e verificá-lo. Parabéns ao autor Você pode usá-lo gratuitamente, mas a reutilização desse código em publicações e regida pelas Regras da Casa.
Para acesso rápido no gráfico, adicione esse script para seus favoritos — saiba mais aqui.
Aviso legal
As informações e publicações não devem ser e não constituem conselhos ou recomendações financeiras, de investimento, de negociação ou de qualquer outro tipo, fornecidas ou endossadas pela TradingView. Leia mais em Termos de uso.
Script de código aberto
No verdadeiro espirito do TradingView, o autor desse script o publicou como código aberto, para que os traders possam entendê-lo e verificá-lo. Parabéns ao autor Você pode usá-lo gratuitamente, mas a reutilização desse código em publicações e regida pelas Regras da Casa.
Para acesso rápido no gráfico, adicione esse script para seus favoritos — saiba mais aqui.
Aviso legal
As informações e publicações não devem ser e não constituem conselhos ou recomendações financeiras, de investimento, de negociação ou de qualquer outro tipo, fornecidas ou endossadas pela TradingView. Leia mais em Termos de uso.