Changeset 14226
- Timestamp:
- 08/02/16 16:16:29 (8 years ago)
- Location:
- trunk/sources
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.DataAnalysis.Trading/3.4/Calculators/OnlineSharpeRatioCalculator.cs
r14185 r14226 31 31 public double SharpeRatio { 32 32 get { 33 if (meanAndVarianceCalculator. Variance > 0)34 return meanAndVarianceCalculator.Mean / Math.Sqrt(meanAndVarianceCalculator. Variance);33 if (meanAndVarianceCalculator.PopulationVariance > 0) 34 return meanAndVarianceCalculator.Mean / Math.Sqrt(meanAndVarianceCalculator.PopulationVariance); 35 35 else return 0.0; 36 36 } … … 46 46 public OnlineCalculatorError ErrorState { 47 47 get { 48 return meanAndVarianceCalculator.MeanErrorState | meanAndVarianceCalculator. VarianceErrorState | profitCalculator.ErrorState;48 return meanAndVarianceCalculator.MeanErrorState | meanAndVarianceCalculator.PopulationVarianceErrorState | profitCalculator.ErrorState; 49 49 } 50 50 } -
trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/OnlineNormalizedMeanSquaredErrorCalculator.cs
r14185 r14226 30 30 public double NormalizedMeanSquaredError { 31 31 get { 32 double var = originalVarianceCalculator. Variance;32 double var = originalVarianceCalculator.PopulationVariance; 33 33 double m = meanSquaredErrorCalculator.Mean; 34 34 return var > 0 ? m / var : 0.0; … … 44 44 #region IOnlineCalculator Members 45 45 public OnlineCalculatorError ErrorState { 46 get { return meanSquaredErrorCalculator.MeanErrorState | originalVarianceCalculator. VarianceErrorState; }46 get { return meanSquaredErrorCalculator.MeanErrorState | originalVarianceCalculator.PopulationVarianceErrorState; } 47 47 } 48 48 public double Value {
Note: See TracChangeset
for help on using the changeset viewer.