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

Re: Data Array as Input



PureBytes Links

Trading Reference Links

Ron,

You are on the right track,...

Try this code:

dataarray:=Input("Data array. Enter a number 1=O, 2=H, 3=L, 4=C, 5=V",
1,5,4); {Close is default}
value2:=If(dataarray=1,O,IF(dataarray=2,H,If(dataarray=3,L,If(dataarray=4,C,
If(dataarray=5,V,C)))));

Then use <value2> in you Indicator

Bill
----- Original Message -----
From: "Ron" <ronber@xxxxxxxxxxxxx>
To: <metastock@xxxxxxxxxxxxx>
Sent: Saturday, May 25, 2002 8:12 AM
Subject: Data Array as Input


> I would like to have the data array used (O,H,L,C,V) chosen in a custom
> indicator. It appears the values for Input must be numeric. I've tried
> using 1,2,3,4,5 to assign O,H,L,C,V respectively  and then using nested
> ifs, but that doesn't seem to work. I can create separate indicators and
> hard code the O,H... but  would like to avoid that. Any help is
appreciated.
>
> TIA
> Ron
>
> .
>
>
>