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

Re: [amibroker] Code Help



PureBytes Links

Trading Reference Links

Try this

FACTOR= 0
+ (Name()=="6EH6-GLOBEX-FUT") * 55
+ (Name()=="ER2H6-GLOBEX-FUT") * 50
+ (Name()=="YM   MAR O6-ECBOT-FUT") * 45
;

I set it up this way to allow easy adding/removing of any lines
If you have a general factor for symbols not on your listm then you
will need to use IIF

FACTOR=
iif( (Name()=="6EH6-GLOBEX-FUT"), 55,
iif( (Name()=="ER2H6-GLOBEX-FUT"), 50,
iif( (Name()=="YM   MAR O6-ECBOT-FUT"), 45,
 40 )));


--
Cheers
Graham
AB-Write >< Professional AFL Writing Service
Yes, I write AFL code to your requirements
http://e-wire.net.au/~eb_kavan/ab_write.htm


On 2/5/06, Paul Yarwood <pyarwood@xxxxxxx> wrote:
> For an indicator that I'm working on  I need to set a value for a factor
> DEPENDANT on the security
>
> I need it so that the indicator has the same range of values when it is
> applied to different securities
>
> I have the factor values worked out just need to get them applied to the
> proper security
>
> FACTOR=
> one for the Eruo future 6EH6-GLOBEX-FUT
> one for the Russell future ER2H6-GLOBEX-FUT
> one for the Dow emini YM   MAR O6-ECBOT-FUT
>
> tried using the close price because the prices are very different but ami
> refused to accept my jibberisih
>
> thanks
>
>
>
>
>
> Please note that this group is for discussion between users only.
>
> To get support from AmiBroker please send an e-mail directly to
> SUPPORT {at} amibroker.com
>
> For other support material please check also:
> http://www.amibroker.com/support.html
>
>
> Yahoo! Groups Links
>
>
>
>
>
>
>
>


------------------------ Yahoo! Groups Sponsor --------------------~--> 
Try Online Currency Trading with GFT. Free 50K Demo. Trade 
24 Hours. Commission-Free. 
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to 
SUPPORT {at} amibroker.com

For other support material please check also:
http://www.amibroker.com/support.html

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> To unsubscribe from this group, send an email to:
    amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/