amibroker code

  1. trendtrade

    AFL Modification Work - Payment Basis

    Hello I have an AFL which is generating automated buy and sell trade signals, at the completion of the price bar. The problem is that if it finds 5 different stocks which meets the criteria, then it generates 5 signals for each of them simultaneously at the very same second. All I need to do...
  2. C

    Need afl code for the below inside bar conditions...

    Inside bar Downtrend explorer Conditions for Alert 1.Price less than ema<14 2.Occurance of Inside bar 3.Following candles price action(if any mutiple bars formed) should stay within the Inside bar pattern. ie. thier close should be within the mother candles high. 4.Price break below the...
  3. M

    Need help for Quantity managment.

    Hello All, I have placed the query for placing order from AFL amibroker. with the below conditions. 1) first order should be 1; 2) If any order exited by Stop loss or target (sell or cover) the quantity should be 1; 3) if the stoploss or target not hit then the queantity should be 2; way...
  4. T

    Fixing the first bar of the day as the first bar on Amibroker chart

    Hello, I trying to do this for a long time but have not been able to do it. I am posting this after unsuccessfully searching the internet. I want to fix the "first bar of the day" on the left hand side like the picture below and to have the new bars get added to it on the right side. So that...
  5. P

    highest days of EMA broke today

    Hi, I want to find how many max days EMA stock break today? if C>EMA(5) is true & C<EMA(6) is false then afl should return 5 since close broke max of 5 days ema. this things should run in loop for 1 yr say 365 loops total Can help me with this afl. Regards, Paresh
  6. W

    Amibroker ADX Barssince >> Still Learning << :(

    Hello programmers, I am a slow learner please forgive this amateur question. I hope you can please assist me or guide me please. All I am trying to do is make the PDI Range greater than MDI adx range for 10 bars or more before buy is executed. I just don't understand "barssince" or if its...
  7. S

    AFL CODE: simple downtrend, I am wrong! :(

    Hello, I have tried to make just a simple downtrend: I tried to make 3 red bars, but its not working. If someone could please correct me, I know its an amateur question but i'm still learning. Buy= C< Ref(C,-1) AND Ref(C,-1) < Ref(C,-2) AND Ref(C,-2) < Ref(C,-3);/// I thought this would...
  8. S

    AFL code help

    I want to create an amibroker AFL code as per the below requirements. 1. The rectangle should automatically extend to the right side when drawn on the chart. 2. The rectangle should display the price values on the upper and lower line of the rectangle [Right Side extend]. 3...
  9. J

    ADvance Decline line in Amibroker

    I have added the Adline() to my $nya chart but it is empty. What am I doing wrong?
  10. A

    Exit at next Day at 9:16 am (intraday trade)

    Hello friends, This afl is for intraday trade. I am new to amibroker afl and was struck in this part.How to exit at next day am or trade next day. I have tried some afl. SetTradeDelays(1,1,1,1); //Open at sell at next day open SellPrice=Open; Thanks for help!!!
  11. C

    How to compare current and previous candle in Amibroker AFL?

    In my logic I need to find out the candle which makes new high as compared to latest 5 candles. And the candle must be a red candle which means its CLOSE<OPEN. As well as it should look more like an inverted hammer for which I have written something like this- O<(H-L)/2 Now the biggest...
  12. Sagarocks432

    Ref function not working properly.

    I am trying on a code which contains ref function. But when I take ref function as -1 it count it as 5 candles and give scan result after 5 candles. Even when I divide it by 5 it wont work properly. I tried in 3 diff version of amibroker. Kindly help :confused: TimeFrameSet(in5Minute); a...