Dear Anant I guess he is not talking abt buying randomly above the high of any random bar in randomly picked stock. Perhaps he has any trading set up n he want to buy above the high of the bar where buy signal is generated. If this is the case I suggest thread owner to post his full afl only then any1 can help him.
Otherwise this may work for buying abv the high in next bar
Buy= C> ref(HHV,-1);
Otherwise this may work for buying abv the high in next bar
Buy= C> ref(HHV,-1);
As per Amibroker help file, the syntax is:
Code:
hhv( ARRAY, periods )