Code cleanup.
This commit is contained in:
@@ -1,16 +1,12 @@
|
||||
using MarketData.Cache;
|
||||
using MarketData.DataAccess;
|
||||
using MarketData.Generator.Indicators;
|
||||
using MarketData.Generator.MovingAverage;
|
||||
using MarketData.Helper;
|
||||
using MarketData.MarketDataModel;
|
||||
using MarketData.Numerical;
|
||||
using MarketData.Utils;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace MarketData.Generator.CMTrend
|
||||
{
|
||||
@@ -206,7 +202,8 @@ namespace MarketData.Generator.CMTrend
|
||||
}
|
||||
|
||||
// Trend #8 check. Evaluate the RSI
|
||||
RSICollection rsiCollection=RSIGenerator.GenerateRSI(symbol,currentPrice.Date,30); // generate a 14 day standard RSI with 30 days of pricing data
|
||||
// generate a 14 day standard RSI with 30 days of pricing data
|
||||
RSICollection rsiCollection=RSIGenerator.GenerateRSI(symbol,currentPrice.Date,30);
|
||||
if(null==rsiCollection||0==rsiCollection.Count||rsiCollection[rsiCollection.Count-1].RSI<cmtParams.MinRSI)
|
||||
{
|
||||
cmtCandidate.Violation=true;
|
||||
|
||||
@@ -71,8 +71,8 @@ namespace MarketData.Generator.CMTrend
|
||||
MaxBeta=10.00; // Candidates with Beta that exceed this are rejected.
|
||||
UseMaxBeta=false; // Utilize the MaxBeta filter
|
||||
UseProfitMaximization=true; // Maximize profits when setting stop limits. What this does is to instead of using 3*ATR(20) it will use UseProfitMaximizationATRMultiplier*ATR(20) to set the stop limit for R's greater than or equal to UseProfitMaximizationRs
|
||||
UseProfitMaximizationExpression="R_THRESSHOLD=4;MAX_ATR=3;MULTIPLIER=MAX_ATR;IF(RMultiple>=R_THRESSHOLD){MULTIPLIER=1.2;}";
|
||||
UseTradeOnlySectors=false; // If set to true then only consider companies in specified sector
|
||||
UseProfitMaximizationExpression="R_THRESSHOLD=4;MAX_ATR=3;MULTIPLIER=MAX_ATR;IF(RMultiple>=R_THRESSHOLD){MULTIPLIER=1.2;}"; // The default ATR multiplier is 3 which will maintain a wider gap. 1.2 will follow more closely
|
||||
UseTradeOnlySectors=false; // If set to true then only consider companies in specified sectors
|
||||
UseTradeOnlySectorsSectors="Healthcare,Technology,Basic Materials,Consumer Defensive,Industrials";
|
||||
}
|
||||
public bool SuspendTrading{get;set;}
|
||||
|
||||
Reference in New Issue
Block a user