Category Archives: AUTOTRADING

  • -

Best MCX Commodity Strategy Amibroker AFL – Intraday Positional

BEST MCX COMMODITY INTRADAY AFL

 

// Downloaded From www.crudeoperator.com
TimeFrameSet(inDaily);
DayHigh = LastValue(H);
DayLow = LastValue(L);
TimeFrameRestore();

Title = Date() + “, Op=” + Open + “, Hi=” + High + “, Lo=” + Low + “, LTP=” + Close + “, Change= ” + SelectedValue( ROC( C, 1 ) ) + “%” + “\n Today`s High=” + DayHigh + “, Today`s Low=” + DayLow + ” © PRIME SYSTEM” ;

prev=AMA2(C,1,0);
d=IIf(C>Ref(Max(Max(H,Ref(H,-20)),Max(Ref(H,-10),Ref(H,-15))),-1),Min(Min(L,Ref(L,-20)),Min(Ref(L,-10),Ref(L,-15))),
IIf(C<Ref(Min(Min(L,Ref(L,-20)),Min(Ref(L,-10),Ref(L,-15))),-1),Max(Max(H,Ref(H,-20)),Max(Ref(H,-10),Ref(H,-15))),PREV));
a=Cross(Close,d);
b=Cross(d,Close);
state=IIf(BarsSince(a)<BarsSince(b),1,0);
s=state>Ref(state,-1);
ss=state<Ref(state,-1);
sss=state==Ref(state,-1);
col=IIf(state == 1 ,51,IIf(state ==0,4,1));
Plot(C,””,Col,64);
Buy = s;
Sell = ss;
shape = Buy * shapeUpArrow + Sell * shapeDownArrow;
PlotShapes(shape, IIf(Buy,colorGreen,colorRed), 0, IIf(Buy,Low,High));
PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorGreen, 0, L, Offset=-10);
PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorLime, 0,L, Offset=-20);
PlotShapes(IIf(Buy, shapeUpArrow, shapeNone),colorWhite, 0,L, Offset=-15);
PlotShapes(IIf(Sell, shapeSquare, shapeNone),colorRed, 0, H, Offset=20);
PlotShapes(IIf(Sell, shapeSquare, shapeNone),colorOrange, 0,H, Offset=30);
PlotShapes(IIf(Sell, shapeDownArrow, shapeNone),colorWhite, 0,H, Offset=-25);
//WriteIf(s,”EXIT all Short positions\nif trading long positions, enter long Now-\nOR at the market price on tomorrow’s Open with stop=”+EncodeColor(4)+WriteVal(L+.75*ATR(5),1.4)+” ,”,””);
//WriteIf(ss,”exit all long positions today with a Market On Close (MOC) order\nOR at the market price on tomorrow’s Open with stop=”+EncodeColor(4)+WriteVal(Ref(H+.75*ATR(5), -1),1.4)+”,”,””);
//WriteIf( sss ,”No trading signals today.”,””) ;

dist = 0.8*ATR(10);
dist1 = 2*ATR(10);
for( i = 0; i < BarCount; i++ )
{
if( Buy[i] )
{
PlotText( “\nBuy:” + L[ i ] + “\nT= ” + (L[i]*1.005) + “\nSL= ” + (L[i]*0.9975), i, L[ i ]-dist[i], colorGreen, colorWhite );
}
if( Sell[i] )
{
PlotText( “Sell:” + H[ i ] + “\nT= ” + (H[i]*0.995) + “\nSL= ” + (H[i]*1.0025), i, H[ i ]+dist1[i], colorRed, colorWhite );
}
}

Filter = s OR sss OR sss ;
AddColumn(C,”close”,1.2);
AddColumn( IIf( s, 66,1 ), “buy”, formatChar, 1, bkcolor =IIf (s,colorYellow, colorPink ));
AddColumn( IIf( Ss, 83,1 ), “sell”, formatChar, 1, bkcolor =IIf (Ss,colorPink, colorWhite ));
AddColumn( IIf( sss, 87,1 ), “wait”, formatChar, 1, bkcolor =IIf (sss,colorYellow, colorRed ));

_SECTION_BEGIN(“swing1″);
no=20;
res=HHV(H,no);
sup=LLV(L,no);
avd=IIf(C>Ref(res,-1),1,IIf(C<Ref(sup,-1),-1,0));
avn=ValueWhen(avd!=0,avd,1);
supres=IIf(avn==1,sup,res);
a=Cross(C,supres);
b=Cross(supres,C);
style = a * styleStaircase + b * styleStaircase;
PlotShapes(a,style, IIf(a,colorGreen,colorRed), 0, IIf(a,Low,High));
Plot(supres,”Swing”,colorYellow,styleStaircase);
_SECTION_END();

_SECTION_BEGIN(“trend”);
uptrend=PDI(20)>MDI(10)AND Signal(29)<MACD(13);
downtrend=MDI(10)>PDI(20)AND Signal(29)>MACD(13);
Plot( 2, /* defines the height of the ribbon in percent of pane width */”ribbon”,
IIf( uptrend, colorGreen, IIf( downtrend, colorRed, 0 )), /* choose color */
styleOwnScale|styleArea|styleNoLabel, -0.5, 100 );
_SECTION_END();

Buy = s AND a AND uptrend ;
Short = ss AND b AND downtrend ;
Sell = ss AND b AND downtrend ;
Cover = s AND a AND uptrend ;

Buy=ExRem(Buy,Sell);
Sell=ExRem(Sell,Buy);
Cover=ExRem(Cover,Short);
Short=ExRem(Short,Cover);

Filter=Buy OR Sell;
Filter= Cover OR Short;

AddColumn( Buy, “Buy”, 1);
AddColumn(Sell, “Sell”, 1);
AddColumn(Close,”Close”,1.2);
AddColumn(Volume,”Volume”,1.0);

// Plot the Buy and Sell arrows.
shape = Buy * shapeUpArrow + Sell * shapeDownArrow;
PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorGreen, 0, L, Offset=-10);
PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorLime, 0,L, Offset=-20);
PlotShapes(IIf(Buy, shapeUpArrow, shapeNone),colorWhite, 0,L, Offset=-15);
PlotShapes(IIf(Sell, shapeSquare, shapeNone),colorRed, 0, H, Offset=20);
PlotShapes(IIf(Sell, shapeSquare, shapeNone),colorOrange, 0,H, Offset=30);
PlotShapes(IIf(Sell, shapeDownArrow, shapeNone),colorWhite, 0,H, Offset=-25);

//plot volume graph
_SECTION_BEGIN(“Volume”);
Plot( Volume, _DEFAULT_NAME(), ParamColor(“Color”, colorLightGrey ), styleNoTitle | ParamStyle( “Style”, styleHistogram | styleOwnScale | styleNoLabel, maskHistogram ), 2 );
_SECTION_END();

// set background gradient colours
SetChartBkGradientFill( ParamColor(“BgTop”, ColorRGB( 172,172,172 )),ParamColor(“BgBottom”, ColorRGB( 102,136,187 )),ParamColor(“titleblock”,ColorRGB( 255,255,255 )));

GraphXSpace = 5;

 

 

Declarer :  www.crudeoperator.com does not take any responsibility for AFL strategy it’s quality. If you use any of this information, use it at your own risk. You are responsible for your own trading decisions. Be sure to verify paper trading , and is applicable to your particular trade.


  • -

MCX Crude Oil Strategy for Amibroker (AFL) – INTRADAY – POSITIONAL

// Downloaded From www.crudeoperator.com
_SECTION_BEGIN("Reverse 10 EMA Strategy");
SetBarsRequired(100000,0);
GraphXSpace = 15;
SetChartOptions(0,chartShowArrows|chartShowDates);
SetChartBkColor(ParamColor("bkcolor",ColorRGB(0,0, 0)));
GfxSetBkMode(0); 
GfxSetOverlayMode(1);
SetBarFillColor(IIf(C>O,ParamColor("Candle UP Color", colorGreen),IIf(C<=O,ParamColor("Candle Down Color", colorRed),colorLightGrey)));
Plot(C,"\nPrice",IIf(C>O,ParamColor("Wick UP Color", colorDarkGreen),IIf(C<=O,ParamColor("Wick Down Color", colorDarkRed),colorLightGrey)),64,0,0,0,0);
 
SetPositionSize(2,spsShares);
par1 = Optimize("par1",10,5,50,1);
A = EMA(C,par1);
Buy = Cross(A,C);
Sell= Cross(C,A);
 
Short = Sell;
Cover = Buy;
 
ApplyStop(stopTypeLoss, 
         stopModePoint, 
         Optimize( "max. loss stop level", 58, 50, 300, 1 ), 
         True ); 
Plot(A,"EMA10",colorRed);
 
PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorGreen, 0, L, Offset=-40);
PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorLime, 0,L, Offset=-50);                      
PlotShapes(IIf(Buy, shapeUpArrow, shapeNone),colorWhite, 0,L, Offset=-45); 
PlotShapes(IIf(Short, shapeSquare, shapeNone),colorRed, 0, H, Offset=40);
PlotShapes(IIf(Short, shapeSquare, shapeNone),colorOrange, 0,H, Offset=50);                      
PlotShapes(IIf(Short, shapeDownArrow, shapeNone),colorWhite, 0,H, Offset=-45);
_SECTION_END();

 

 

 

 

Declarer :  www.crudeoperator.com does not take any responsibility for AFL strategy it’s quality. If you use any of this information, use it at your own risk. You are responsible for your own trading decisions. Be sure to verify paper trading , and is applicable to your particular trade.


  • -

auto trading amibroker benefits

Fully Automated Trading is software to trade the clients share automatically. This means that the broker or the client doesn’t have to be near a system to operate it physically. The software is developed with advanced mathematical protocols and one of a kind algorithm. With the clients own strategies and plans, they can make their profit. Better the plan, better the gain will be. There are many ways a client or a broker can strategics their earnings.

auto trading amibroker benefits - mcx crude oil intraday

Ways to get better results.

  • The client can plan to use the Cash vs. future bidding NFO/NSE, BFO/BSE. This is an arbitrage algorithm which gives live data of the difference between the cash and future
  • Another option is Future vs. Future Binding NFO/CDS/BFO. It rolls over arbitrage that tries to process the user-defined cost difference between the future segment and cash.
  • Next is Cash vs. Future Arbitrage NFO/NSE. This is another arbitrage algorithm that handles the situation where the same exchange takes place between the user-defined price of the future segment and the cash.
  • The other is Option Hit Model (2L3L IOC NFO/CDS). It helps the clients to generate 2leg/3leg combination which includes straddle/butterfly/strangle and many more.
  • Next is Conrev Bid NFO/CDS. This procedure exploits inconsistencies in the estimation of synthetic positions or infringement of put-call equality rule. Offering technique under a specific condition gives you more than the client’s ideal order.

Few Other important Strategies

  • Now let’s talk about the next strategy. 4L Strategy (IOC + Bid) NFO/CDS is a 4-Leg Strategy that allows all the clients to generate 4 leg option combinations. Among which the orders are in the form of 3-Leg IOC + 1.
  • In this strategy, the user has the choice of whether to place orders bidding based or IOC based. Next is Option 4L IOC Strategy NFO/CDS. Now, this is a 4-Leg Strategy that allows clients to generate any 4 leg option combination like Condor Strategy. Orders are placed in the form of 3-Leg IOC + 1.
  • 2L3L bidding NFO/CDS/BFO is one of the strategies that give the users a privilege to create any 2leg/3leg combination which includes straddle/butterfly /strangle and many more. It is a bidding strategy with the specific condition; where the user can get more.
  • Future vs. Future Arbitrage NFO/CDS/BFO. It is a rollover arbitrage strategy which will place an IOC order (2-Leg), whenever the market spanning is greater or equal to the user-required limitations.
  • Implicit vs. Explicit Spread NFO is an arbitrage strategy between day spread (explicit) and 2l IOC (implied). If the client specified order is better than the market spread. The machine will place an order for 2L IOC on the trade of implicit.

Advantages of Fully Automated Trading

  • One of the most critical benefits of Fully Automated Trading System is minimizing emotions. As the whole process is automatic, the client doesn’t have to keep much in their head. They can peacefully do the entire task.
  • Second is achieving the plan. As we know that having a loss is a part of life. The clients can get losses at some point of the trade. But when we use the automated trading software, there is no chance the client or the broker will have any significant
  • This function helps to make a lot of trade profit for the clients. One of the most important advantages is it improves the speed of the order entry. We know that the stock market fluctuates a lot and with that the client’s profit and loss too. To resolve that, these trading helps the client too quickly buy and sell the share to get the most benefit out of every
  • Another process that effects the Fully Automated trading is back testing. In this process, the system relies on the algorithm and the protocols embedded in the system to work on the stocks. The app uses all the historical data to get present and future data for a better profit margin in every trade.

Conclusion

It is a big step towards the stock market and trading analysis. The fully automated trading saves a lot of time and gives maximum profit to the brokers and clients. To work on this platform, the client needs professional workers who can handle the software and al the trades.


Paid Trial

Translate »