PureBytes Links
Trading Reference Links
|
Hello everyone,
Meisels - here was an indicator that I thought was going to be a
'doddle' (easy). Looking at the definitions in the books I decided to
give it a go. Here they are:
"The sum of the plus or minus observations day to day."
"... the net number of times the market has closed up and down over the
past 'n' periods (default is 10)."
Unfortunately, despite hours of pouring over it, trying CUM()'s and a
variety of nested IIF()'s I cannot get it to look quite right. Here's
my most recent attempt...
===========================================================
/* Meisels Indicator (10 Day)
NOT FULLY CHECKED OR TESTED YET */
days = 10 ;
lastclose = REF( close, days * -1 ) ;
change = IIF( close > lastclose, 1,
IIF( close < lastclose, -1, 0 ) ) ;
graph0 = CUM( change ) ;
===========================================================
I don't think the CUM() function is doing what I expect it to. Can
anyone throw any light on how to improve this?
Knowing my luck, I bet it's something simple that just escapes me :-)
Thanks in advance for any suggestions.
Peter
--
======================================================================
Peter Carr
Email: pcarr@xxxx ICQ: 22586379
======================================================================
|