It looks like you're new here. If you want to get involved, click one of these buttons!
Node JS client
.Net API client
.Net / VBA / Excel (3rd party)
Algorithms and Strategies
Mobile and Desktop apps
Market data (WebSockets)
In this Discussion
is there any updates on
"Internal dynamic execution range at Zerodha".
Zerodha mentioned in the following link "To calculate this impact cost, the system will consider the best five bids and offers and the quantities available at those prices while placing the order".
How I can code those in Python. Do I need to get the best five Ask for buy or Bid for sell. But the freak trades still can appear in the Bid/Ask market depth.
Please help me giving the logic.
We are testing this internally to ensure it smooth and fully accurate. Hoping to be live with this by this month.
If you'd like to do your own basic version of it, you can calculate the weighted average price of Asks(for Buy) or Bid(for Sell) with the LTP or prev close and set an internal % of spread that you'd like to trade/not trade with.
Thank you so much Faisal.
Does freak trade appears in Bid/Ask market depth as it appears in High/Low prices.
I just want to take the min(Bid/Ask market depth)*1.2 and pass it as a limit price for a buy order to cover a short position programmatically. Does this approach eliminate the risk of freak trades?
Please give some logic.
A freak trade happens when a market order of a large quantity ends up filing all the depth increasing(buy) or decreasing(sell) the price significantly. With the % you are setting you are ensuring that your orders dont cause a freak trade.
Sorry to ask you more doubts.
Does a freak trade increase both Bid and Ask together or any one of them.