TradingView
cheatcountry
2021年5月20日下午5點35分

Volume Positive Negative Indicator [CC] 

Apple Inc.NASDAQ

描述

The Volume Positive Negative Indicator was created by Markos Katsanos (Stocks and Commodities April 2021 pg 9) and this indicator is useful for determining long trends but with some modification you can use it for short trends as well. Buy when the indicator line is green and sell when it turns red. Make sure to experiment with the threshold and see what works best for you.

Let me know if there are any other indicators you want me to publish!
評論
OrcChieftain
I've just added hlines to the code

For anyone who wants the hlines, add this to the code:

hline_color = color.new(color.gray, 80)
hline1 = hline(20, linestyle = hline.style_solid, color = hline_color)
hline2 = hline(-20, linestyle = hline.style_solid, color = hline_color)
hline3 = hline(0, linestyle = hline.style_solid, color = hline_color)
hline4 = hline(80, linestyle = hline.style_solid, color = hline_color)
hline5 = hline(-80, linestyle = hline.style_solid, color = hline_color)

The first number in the brackets is the level that it will appear at. 20, -20, 0, 80, and -80

Even though the original script has no hlines, these numbers are mentioned on M. Katsanos's webpage dedicated to this indicator.
OrcChieftain
What a lovely script. I will study it this weekend!

//* by the way, why not request hlc3 in one row? *//
cheatcountry
@greenmask9, this was released before they included hlc3 as a variable but I use it in all of my current scripts. Thank you btw
OrcChieftain
@cheatcountry, Oh, I see
r4ranjith
Where do I signup for your AI program
cheatcountry
@r4ranjith, just send me a pm
GarySethi19
What type of modifications would be needed on smaller time frames such as 5-15?
Thank you ahead of time
cheatcountry
@GarySethi19, It would still work the same with smaller time frames but for shorter trend detection, you would just need to lower the threshold amount
更多