public LongTermVolExpectedReturn() { TargetVol = 0.06; ShouldIncludeInstrument = (comId_, date_) => true; LowerLimit = (comid_, date_) => (comid_.IsSector(ComSector.Meats) || comid_.IsSector(ComSector.Softs) || String.Compare("Lead", comid_.Name, StringComparison.OrdinalIgnoreCase) == 0) ? -0.15 : -0.3d; UpperLimit = (comid_, date_) => (comid_.IsSector(ComSector.Meats) || comid_.IsSector(ComSector.Softs) || String.Compare("Lead", comid_.Name, StringComparison.OrdinalIgnoreCase) == 0) ? 0.15 : 0.3d; RebalFreq = Backtest.RebalFreq.Monthly; var spots = Singleton<ComIndexPrices>.Instance.GetData(DataConstants.DATA_START, DateTime.Today).ToReturns(); LongTermVols = spots.ProcessEachColumn((dailyRetunrs) => HelperMethods.GetRollingStat(dailyRetunrs, 750, Statistics.Stdev)); EER = (comid_, date_) => LongTermVols.GetValue_Previous(date_, comid_.ArrayIndex); }