I'm trying to determine the matlab method of creating an "Adaptive Algo" order in the Interactive Broker api. The c# method is stated here: https://interactivebrokers.github.io/tws-api/ibalgos.html#adaptive however, I can't figure out its matlab equivalent
C#:
Order baseOrder = OrderSamples.LimitOrder("BUY", 1000, 1);... AvailableAlgoParams.FillAdaptiveParams(baseOrder, "Normal"); client.placeOrder(nextOrderId++, ContractSamples.USStockAtSmart(), baseOrder);... public static void FillAdaptiveParams(Order baseOrder, string priority) { baseOrder.AlgoStrategy = "Adaptive"; baseOrder.AlgoParams = new List<TagValue>(); baseOrder.AlgoParams.Add(new TagValue("adaptivePriority", priority)); }
What I've done so far in Matlab:
% Create TWS connection and Create Order
ib = ibtws('',7496);ibOrder = ib.Handle.createOrder;ibOrder.action = 'BUY';ibOrder.totalQuantity = 1000;ibOrder.orderType = 'LMT';% Specifying Adaptive Algo Order
ibOrder.algoStrategy = "Adaptive";
Best Answer