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

AFL Mystery - 4th



PureBytes Links

Trading Reference Links

Hi,

I had thought that meanwhile I had found a solution:

isCci = cci() > -100;
isBullish = ema(c, 5) > ema(co, 21) and ema(co,21) > ema(co,45);
isUp = ema(c, 5) > ema( ref(c, -2), 5);

buy = isCci AND isBullish AND isUp ;
buyprice = valuewhen( buy, ref(open, 1), 1);

minGrowth = (close > buyprice * 1.08);
stopLoss = (close < buyprice * 0.97);

sell = minGrowth or stopLoss ;

buy = exrem(buy, sell);
sell = exrem(sell, buy);

filter = 1;
numcolumns = 4;
column0 = c; column0name = "c";
column1 = buyprice; column1name = "buyprice";
column2 = sell; column2name = "sell";
column3 = buy; column3name = "buy";

But now I find that the 'buyprice' is sometimes correct and at other times
it changes without 'buy' occurring.

Some ideas?

Cheers - Ralf