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

[amibroker] Re: How to extract position in (non time based) array - AFL EXPERTS?


  • Date: Mon, 21 Dec 2009 21:52:18 -0000
  • From: "kevinoversby" <kevinoversby@xxxxxxxxx>
  • Subject: [amibroker] Re: How to extract position in (non time based) array - AFL EXPERTS?

PureBytes Links

Trading Reference Links

Thanks Ara,

I tried it like this:

y[1]=1103; y[2]=1107; y[3]= 1095; y[4]= 1100;
x = ValueWhen(HHVBars(y,4)==0,BarIndex());

but get 16,758 rather than 2 - is there another way to write it?

Looks like a simple problem!


Kevin

--- In amibroker@xxxxxxxxxxxxxxx, "Ara Kaloustian" <ara1@xxx> wrote:
>
> use valuewhen function and return the barindex() value
> 
> ----- Original Message ----- 
> From: "kevinoversby" <kevinoversby@xxx>
> To: <amibroker@xxxxxxxxxxxxxxx>
> Sent: Monday, December 21, 2009 12:31 PM
> Subject: [amibroker] How to extract position in (non time based) array
> 
> 
> >I can't find a function in the reference to do this.
> > 
> > For example, I have an array of the last 4 highs (from Zig function):
> > 
> > {1103 1107 1095 1100}
> > 
> > I want to return the index of the highest value (i.e 2).
> > 
> > Is there a way to do this?
> > 
> > 
> > Thanks
> > 
> > Kevin
> > 
> > 
> > 
> > 
> > 
> > ------------------------------------
> > 
> > **** IMPORTANT PLEASE READ ****
> > This group is for the discussion between users only.
> > This is *NOT* technical support channel.
> > 
> > TO GET TECHNICAL SUPPORT send an e-mail directly to 
> > SUPPORT {at} amibroker.com
> > 
> > TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
> > http://www.amibroker.com/feedback/
> > (submissions sent via other channels won't be considered)
> > 
> > For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
> > http://www.amibroker.com/devlog/
> > 
> > Yahoo! Groups Links
> > 
> > 
> > 
> >
>




------------------------------------

**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to 
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

Yahoo! Groups Links

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

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/amibroker/join
    (Yahoo! ID required)

<*> To change settings via email:
    amibroker-digest@xxxxxxxxxxxxxxx 
    amibroker-fullfeatured@xxxxxxxxxxxxxxx

<*> 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/