PureBytes Links
Trading Reference Links
|
Hi Barry,
Thank you for your answer. Once again, what I want to do is to create an RSI where
I use a custom formula for the # of days.
Starting with the formula from Chande & Kroll for "Indexing DMI to volatility" I
wrote:
{Dynamic RSI}
{===========}
LenStd:=5;
LenMovStd:=10;
Numratr:=14;
MinDays:=5;
MaxDays:=30;
MovStd:=Mov(Stdev(C,LenStd),LenMovStd,S);
VolaIdx:=Stdev(C,LenStd)/MovStd;
NumDays:=Int(Numratr/VolaIdx);
NumDays:=Min(Max(NumDays,MinDays),MaxDays);
RSI(NumDays)
All of this works just fine - but for the very last line, i.e. the RSI-Part because
in the words of MS: "This variable or expression must contain only constant data".
Not accepting time as a variable is found all over the built-in functions of MS
:-(
In consequence the only solution is to write a custom RSI which I haven't gotten
around to.
~~~~ Has anyone done so? If so, please drop me a line. ~~~~
Thanx & Happy Trading,
Jan Willem Roberts
Barry Spreen wrote:
> Replying off list -
> What are your specifications for changing the periods in RSI? It sounds like an
> educational problem. If I come up with anything you can post it to the list.
>
> Best
> Barry
|