19 using System.Collections.Generic;
21 using System.Reflection;
30 private decimal _startingCash;
31 private List<Order> _orders;
42 _startingCash = startingCash;
43 _orders = orders.ToList();
44 _algorithmConfiguration = algorithmConfiguration;
53 foreach (var symbol
in orders.Select(x => x.Symbol).Distinct())
56 switch (symbol.SecurityType)
67 var configs =
SubscriptionManager.SubscriptionDataConfigService.Add(symbol, resolution,
false,
false);
75 security.SetLeverage(10000m);
77 var method = typeof(
QCAlgorithm).GetMethod(
"AddToUserDefinedUniverse", BindingFlags.NonPublic | BindingFlags.Instance);
78 method.Invoke(
this,
new object[] { security, configs });
87 if (_algorithmConfiguration !=
null)
95 if (_orders.Count != 0)