Removed references to SharpeRatioRiskAllocation

This commit is contained in:
2025-01-14 12:44:57 -05:00
parent 441b8e97ff
commit 323b259fc5

View File

@@ -1,20 +1,10 @@
using System;
using System.Collections.Generic;
using System.Text;
using MarketData.MarketDataModel;
using MarketData.DataAccess;
using MarketData.Utils;
using System.Linq;
using MarketData.Helper;
using MarketData.Numerical;
namespace MarketData.Generator.Momentum
{
public class MGConfiguration
{
// public static double ATR_MULTIPLIER=3;
public static String RISK_ALLOCATION_SHARPE_RATIO = "SharpeRatio";
public static String RISK_ALLOCATION_NONE = "None";
// Operational Settings
public bool Verbose{get;set;}
// Basic settings
@@ -27,8 +17,6 @@ namespace MarketData.Generator.Momentum
// Fundamental screenings
public double MarketCapLowerLimit{get;set;}
// public String RiskAllocation { get; set; } // Valid values are "None"/"SharpeRatio"
public bool UsePEScreen{get;set;} // If set this filter will ignore any security that is either missing a PE or if the PE is present but less than 0
public bool UseMaxPEScreen{get;set;} // control Max PE range check
@@ -76,7 +64,6 @@ namespace MarketData.Generator.Momentum
public MGConfiguration()
{
Verbose=true; // user verbose output
// RiskAllocation = RISK_ALLOCATION_NONE; // Risk Allocation
BenchmarkMode=false; // set this to true if you want to run the model using just the benchmark symbol to buy.
BenchmarkModeSymbol="SPY"; // SPY is the default symbol to buy when testing
HoldingPeriod=3; // 3 is the default
@@ -154,7 +141,6 @@ namespace MarketData.Generator.Momentum
nvpCollection.Add(new NVP("UseMaxPEScreen",UseMaxPEScreen.ToString()));
nvpCollection.Add(new NVP("MaxPE",MaxPE.ToString()));
nvpCollection.Add(new NVP("StrictMaxPE",StrictMaxPE.ToString()));
// nvpCollection.Add(new NVP("RiskAllocation", RiskAllocation.ToString()));
nvpCollection.Add(new NVP("QualityIndicatorType",QualityIndicatorType.ToString()));
nvpCollection.Add(new NVP("IncludeTradeMasterForSymbolsHeld",IncludeTradeMasterForSymbolsHeld.ToString()));
return nvpCollection;
@@ -194,9 +180,6 @@ namespace MarketData.Generator.Momentum
mgConfiguration.FallbackCandidate=nvpDictionary["FallbackCandidate"].Get<String>();
mgConfiguration.FallbackCandidateBestOf=nvpDictionary["FallbackCandidateBestOf"].Get<String>();
//if (nvpDictionary.ContainsKey("RiskAllocation")) mgConfiguration.RiskAllocation = nvpDictionary["RiskAllocation"].Get<String>();
//else mgConfiguration.RiskAllocation = RISK_ALLOCATION_NONE;
if(nvpDictionary.ContainsKey("QualityIndicatorType")) mgConfiguration.QualityIndicatorType=nvpDictionary["QualityIndicatorType"].Get<String>();
else mgConfiguration.QualityIndicatorType=QualityIndicator.ToString(QualityIndicator.QualityType.IDIndicator);
@@ -244,8 +227,6 @@ namespace MarketData.Generator.Momentum
MDTrace.WriteLine(LogLevel.DEBUG,String.Format("BenchmarkMode,{0}",BenchmarkMode));
MDTrace.WriteLine(LogLevel.DEBUG,String.Format("BenchmarkSymbol,{0}",BenchmarkModeSymbol));
// MDTrace.WriteLine(LogLevel.DEBUG, String.Format("RiskAllocation,{0}", RiskAllocation));
MDTrace.WriteLine(LogLevel.DEBUG,String.Format("QualityIndicatorType,{0}",QualityIndicatorType));
MDTrace.WriteLine(LogLevel.DEBUG,String.Format("IncludeTradeMasterForSymbolsHeld,{0}",IncludeTradeMasterForSymbolsHeld));