[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MA types as INPUT



PureBytes Links

Trading Reference Links

At 03:03 PM 9/18/98 +0930, you wrote:
>Chuck
>
>You can input only numbers as far as I am aware.
>
>However, by assigning numbers to do a certain type of moving average you
>could accomplish what you require.
>
>eg
>
>matype:=input("enter MAA type 1=simple, 2= exponential"),1,2,2);
>
>maout:=if(matype=1,mov(c,periods,S),
>                if(matype=2,mov(c,periods,E),{otherwise}0));
>
>this will generate a simple or exponential MA depending on input
>
>Regards ... Martin


Martin--

Thanks for your suggestion. I will be away over the weekend but will try it
out next week. It certainly makes sense at first look--

Chuck