OPEN-SOURCE SCRIPT

% Sensitivity MA

已更新
Modifying an existing indicator is one thing, but creating an entirely new indicator is a totally different thing that involves even more creativity!
Today, I accomplished the latter by creating a brand new indicator. It's called "% Sensitivity MA". What does it do? Well, it's pretty much like any moving average, it tells you the trend. When the % Sensitivity MA is green, it's an uptrend, and vise versa for when it's red. Here's the calculation:

% Sensitivity MA (n,src) = ma.prev + (n/100) * (src - ma.prev)

where:
n - parameter that determines % sensitivity from 0 to 100.
src - parameter that determines the source. (default: close)
ma.prev - previous value of % Sensitivity MA.

Note:
- % Sensitivity MA has no parameter for lookback period.
- The n parameter is limited to a value between 0 and 100.
- Higher n values are more sensitive. (So, 100 is maximum sensitivity.)
- The value of the n parameter can have an unlimited number of decimal places. (making this indicator very precise!)
- I recommend n values closer to 0 than 100.
- For the source, I recommend closing prices.

Good luck, and enjoy!
發布通知
>>>
close > ma? ---> green if true, otherwise red.
Moving Averages

開源腳本

在真正的TradingView精神中,這個腳本的作者以開源的方式發佈,這樣交易員可以理解和驗證它。請向作者致敬!您可以免費使用它,但在出版物中再次使用這段程式碼將受到網站規則的約束。 您可以收藏它以在圖表上使用。

想在圖表上使用此腳本?

免責聲明