Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
I understand basic coding, however, this one has me stumped, as I cant figure out the logic of what it is saying. Would appreciate a plain English translation if anyone knows.
private int period = 5
dataseries.set = (MAX(High, period)[0] - MIN(Low, period)[0])
starting from the inside out...
1st (high of the last 5 periods) - (minimum of the last 5 periods)
2nd what does MAX mean here? If you subtract two values, isnt that the max already?
What am I missing?
Thanks.
Can you help answer these questions from other members on NexusFi?
In plain english "Set dataseries to the Highest High of the last 5 bars, as of this current bar, minus the Lowest Low of the last 5 bars, as of this current bar"
MAX() means highest value.
MAX(High, period)[0] means MAX High (High as in OHLC, open high low close), period meaning 5 bars, [0] meaning current bar. MAX(High, period)[1] would mean as of 1 bar ago for example. MAX(High) in trading means "Highest High". But you could also do MAX(Open, period)[0] for example to mean highest Open.