ROC expresses momentum as a percentage: how much price has changed over N bars relative to the prior close. Being unit-free, it compares cleanly across instruments; zero-line crosses and extremes flag momentum shifts. Copy the version for your platform.
inputs: Length(12);
variables: MyROC(0);
MyROC = RateOfChange(Close, Length);
Plot1(MyROC, "ROC");{ROC - Rate of Change, period 12}
rocVal := ROC(C, 12);
rocValTo use it inside dtcharts, paste any version into the Script Converter and it becomes a native indicator on your chart.