OPEN-SOURCE SCRIPT

Feature scaler

By gorx1
Feature scaler | Pine Utilities series, ready to be used in "study-on-study" fashion |

Includes min-max, normalization, standardization and unit length scaling.
One and only source: en.wikipedia.org/wiki/Feature_scaling
Endpoint inputs allow to set an interval of interest for min-max scaler.

Can be (and should be) applied to other studies, or to the chart itself. In this example, I applied min-max scaling to weighted linear regression's slope values.

Unfortunately, "All data" is still "experimental" and works only on charts where less than 5000 bars are available. max_bars_back() didn't help.

Sup TV
featurelengthminmaxnormalizationPine utilitiesscalerscalingstandardizationstatisticsUNIT
gorx1

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