LonesomeTheBlue

Trend Following with Moving Averages

LonesomeTheBlue Wizard 已更新   
Hello Traders,


With the info "Trend is Your Friend", you should not take position against the trend. This script checks multipte moving averages if they are above/below the closing price and try to find trend. The moving averages with the length 8, 13, 21, 34, 55, 89, 144, 233, 377 used. these are fibonacci numbers, but optionally you can change the lengths of each moving averages. while it's green you better take long positions, while it's red you better take short positions according to other indcators or tools.

Optionally you have "smoothing" option to get rid of whipsaws. it's enabled by default.

You have option to use following moving average types: EMA, SMA, RMA, WMA, VWMA. by default it's EMA

Also the script has "Resolution" option. with this option you can get the trend for other time frames, in following example 1h was set as for higher time frame on 15m chart:



This should not be used as buy/sell signal indicators as it's tries to find trend but not entry points, you should use other indicators (such RSI, Momentum) or other tools to find buy/sell signals.


Enjoy!
版本注释:
arrays used
transp removed
版本注释:
smoothing part improved

开源脚本

本着真正的TradingView精神,该脚本的作者将其开源发布,以便交易者可以理解和验证它。为作者喝彩!您可以免费使用它,但在出版物中重复使用此代码受网站规则的约束。 您可以收藏它以在图表上使用。

免责声明

这些信息和出版物并不意味着也不构成TradingView提供或认可的金融、投资、交易或其它类型的建议或背书。请在使用条款阅读更多信息。

想在图表上使用此脚本?