quantproject-developers Mailing List for QuantProject (Page 12)
Brought to you by:
glauco_1
You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(7) |
Nov
(103) |
Dec
(67) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(52) |
Feb
(9) |
Mar
(69) |
Apr
(53) |
May
(80) |
Jun
(23) |
Jul
(24) |
Aug
(112) |
Sep
(9) |
Oct
|
Nov
(58) |
Dec
(93) |
| 2005 |
Jan
(90) |
Feb
(93) |
Mar
(61) |
Apr
(56) |
May
(37) |
Jun
(61) |
Jul
(55) |
Aug
(68) |
Sep
(25) |
Oct
(46) |
Nov
(41) |
Dec
(37) |
| 2006 |
Jan
(33) |
Feb
(7) |
Mar
(19) |
Apr
(27) |
May
(73) |
Jun
(49) |
Jul
(83) |
Aug
(66) |
Sep
(45) |
Oct
(16) |
Nov
(15) |
Dec
(7) |
| 2007 |
Jan
(14) |
Feb
(33) |
Mar
|
Apr
(21) |
May
|
Jun
(34) |
Jul
(18) |
Aug
(100) |
Sep
(39) |
Oct
(55) |
Nov
(12) |
Dec
(2) |
| 2008 |
Jan
(120) |
Feb
(133) |
Mar
(129) |
Apr
(104) |
May
(42) |
Jun
(2) |
Jul
(52) |
Aug
(99) |
Sep
(134) |
Oct
|
Nov
(137) |
Dec
(48) |
| 2009 |
Jan
(48) |
Feb
(55) |
Mar
(61) |
Apr
(3) |
May
(2) |
Jun
(1) |
Jul
|
Aug
(51) |
Sep
|
Oct
(7) |
Nov
|
Dec
|
| 2010 |
Jan
(7) |
Feb
(1) |
Mar
(145) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(8) |
Dec
|
| 2011 |
Jan
(78) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(88) |
Sep
(6) |
Oct
(1) |
Nov
|
Dec
|
| 2012 |
Jan
|
Feb
(1) |
Mar
|
Apr
(6) |
May
(5) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
| 2013 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(2) |
| 2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:28:11
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/WalkForwardLag/WFLagGenomesDebugger In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv12834/WalkForwardTesting/WalkForwardLag/WFLagGenomesDebugger Modified Files: WFLagChosenPositionsDebugInfo.cs Log Message: The code has been changed because now WeightedPositions is a List<WeightedPosition>, while in the previous version they it was a SortedList Index: WFLagChosenPositionsDebugInfo.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/WalkForwardLag/WFLagGenomesDebugger/WFLagChosenPositionsDebugInfo.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** WFLagChosenPositionsDebugInfo.cs 28 Oct 2007 19:01:26 -0000 1.7 --- WFLagChosenPositionsDebugInfo.cs 28 Mar 2010 15:28:02 -0000 1.8 *************** *** 148,152 **** int i = 0; foreach ( string signedTicker in ! wFLagWeightedPositions.DrivingWeightedPositions.Keys ) { drivingAndPortfolioTickers[ i ] = SignedTicker.GetTicker( signedTicker ); --- 148,152 ---- int i = 0; foreach ( string signedTicker in ! wFLagWeightedPositions.DrivingWeightedPositions.SignedTickers.Tickers ) { drivingAndPortfolioTickers[ i ] = SignedTicker.GetTicker( signedTicker ); *************** *** 154,158 **** } foreach ( string signedTicker in ! wFLagWeightedPositions.PortfolioWeightedPositions.Keys ) { drivingAndPortfolioTickers[ i ] = SignedTicker.GetTicker( signedTicker ); --- 154,158 ---- } foreach ( string signedTicker in ! wFLagWeightedPositions.PortfolioWeightedPositions.SignedTickers.Tickers ) { drivingAndPortfolioTickers[ i ] = SignedTicker.GetTicker( signedTicker ); |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:27:09
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv12374/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator Modified Files: PVOStrategy.cs PVOStrategyIntraday.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: PVOStrategy.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/PVOStrategy.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** PVOStrategy.cs 30 Aug 2009 21:43:34 -0000 1.8 --- PVOStrategy.cs 28 Mar 2010 15:27:00 -0000 1.9 *************** *** 405,409 **** { SignedTickers signedTickers = new SignedTickers(); ! foreach(WeightedPosition position in this.pvoPositionsForOutOfSample.WeightedPositions.GetValueList()) if(position.IsLong) { --- 405,409 ---- { SignedTickers signedTickers = new SignedTickers(); ! foreach(WeightedPosition position in this.pvoPositionsForOutOfSample.WeightedPositions) if(position.IsLong) { *************** *** 432,436 **** if( this.areEntryConditionsSatisfied() ) { ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); AccountManager.OpenPositions( marketCloseEventHandler_openPositionsIfTheCase_getWeightedPositionsToInvest(), this.account, 10000.0, this.leverage ); --- 432,436 ---- if( this.areEntryConditionsSatisfied() ) { ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); AccountManager.OpenPositions( marketCloseEventHandler_openPositionsIfTheCase_getWeightedPositionsToInvest(), this.account, 10000.0, this.leverage ); *************** *** 444,448 **** finally{ ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); } #endregion --- 444,448 ---- finally{ ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); } #endregion Index: PVOStrategyIntraday.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/PVOStrategyIntraday.cs,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** PVOStrategyIntraday.cs 30 Aug 2009 21:43:34 -0000 1.6 --- PVOStrategyIntraday.cs 28 Mar 2010 15:27:00 -0000 1.7 *************** *** 478,482 **** { #region manage Overbought case ! this.positionsForOutOfSample.WeightedPositions.Reverse(); try { --- 478,482 ---- { #region manage Overbought case ! this.positionsForOutOfSample.WeightedPositions.ReverseSigns(); try { *************** *** 492,496 **** finally { ! this.positionsForOutOfSample.WeightedPositions.Reverse(); } #endregion --- 492,496 ---- finally { ! this.positionsForOutOfSample.WeightedPositions.ReverseSigns(); } #endregion |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:26:10
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv11954/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers Modified Files: PVOGeneticChooser.cs Log Message: The protecter member this.seedForRandomGenerator is now this.seedForRandomGeneratorForTheGeneticOptimizer Index: PVOGeneticChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers/PVOGeneticChooser.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** PVOGeneticChooser.cs 30 Aug 2009 21:34:10 -0000 1.4 --- PVOGeneticChooser.cs 28 Mar 2010 15:26:02 -0000 1.5 *************** *** 104,108 **** this.overboughtMoreThanOversoldForFixedPortfolio, GenomeManagerType.ShortAndLong, returnsManager, ! this.seedForRandomGenerator); } --- 104,108 ---- this.overboughtMoreThanOversoldForFixedPortfolio, GenomeManagerType.ShortAndLong, returnsManager, ! this.seedForRandomGeneratorForTheGeneticOptimizer); } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:25:46
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv11838/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator Modified Files: PVOGenericStrategy.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: PVOGenericStrategy.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/PVOGenericStrategy.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** PVOGenericStrategy.cs 31 Aug 2009 21:03:46 -0000 1.1 --- PVOGenericStrategy.cs 28 Mar 2010 15:25:39 -0000 1.2 *************** *** 490,494 **** { #region manage Overbought case ! this.positionsForOutOfSample.WeightedPositions.Reverse(); try { --- 490,494 ---- { #region manage Overbought case ! this.positionsForOutOfSample.WeightedPositions.ReverseSigns(); try { *************** *** 504,508 **** finally { ! this.positionsForOutOfSample.WeightedPositions.Reverse(); } #endregion --- 504,508 ---- finally { ! this.positionsForOutOfSample.WeightedPositions.ReverseSigns(); } #endregion |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:25:13
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/FitnessEvaluators In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv11582/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/FitnessEvaluators Modified Files: PVOFitnessEvaluator.cs Log Message: IReturnsManager is now used, instead of ReturnsManager Index: PVOFitnessEvaluator.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/FitnessEvaluators/PVOFitnessEvaluator.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** PVOFitnessEvaluator.cs 30 Aug 2009 21:42:33 -0000 1.2 --- PVOFitnessEvaluator.cs 28 Mar 2010 15:25:05 -0000 1.3 *************** *** 90,94 **** private float getFitnessValue_getFitnessValueActually( ! TestingPositions testingPositions, ReturnsManager returnsManager ) { float fitnessValue = -0.5f; --- 90,94 ---- private float getFitnessValue_getFitnessValueActually( ! TestingPositions testingPositions, IReturnsManager returnsManager ) { float fitnessValue = -0.5f; *************** *** 139,143 **** } ! public double GetFitnessValue(object meaning , ReturnsManager returnsManager ) { float fitnessValue = -0.5f; --- 139,143 ---- } ! public double GetFitnessValue(object meaning , IReturnsManager returnsManager ) { float fitnessValue = -0.5f; |
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv11407/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator Modified Files: PVO_CTOStrategy.cs PVO_OTCStrategy.cs PVO_OTCStrategyLessCorrelated.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: PVO_CTOStrategy.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/PVO_CTOStrategy.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** PVO_CTOStrategy.cs 29 Sep 2008 21:17:48 -0000 1.3 --- PVO_CTOStrategy.cs 28 Mar 2010 15:24:32 -0000 1.4 *************** *** 297,301 **** { #region manage Overbought case ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); try { --- 297,301 ---- { #region manage Overbought case ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); try { *************** *** 309,313 **** finally { ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); } #endregion --- 309,313 ---- finally { ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); } #endregion Index: PVO_OTCStrategy.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/PVO_OTCStrategy.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** PVO_OTCStrategy.cs 29 Sep 2008 21:18:13 -0000 1.7 --- PVO_OTCStrategy.cs 28 Mar 2010 15:24:32 -0000 1.8 *************** *** 289,293 **** { #region manage Overbought case ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); try { --- 289,293 ---- { #region manage Overbought case ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); try { *************** *** 301,305 **** finally { ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); } #endregion --- 301,305 ---- finally { ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); } #endregion Index: PVO_OTCStrategyLessCorrelated.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/PVO_OTCStrategyLessCorrelated.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** PVO_OTCStrategyLessCorrelated.cs 29 Sep 2008 21:18:13 -0000 1.4 --- PVO_OTCStrategyLessCorrelated.cs 28 Mar 2010 15:24:32 -0000 1.5 *************** *** 216,220 **** { #region manage Overbought case ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); try { --- 216,220 ---- { #region manage Overbought case ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); try { *************** *** 228,232 **** finally { ! this.pvoPositionsForOutOfSample.WeightedPositions.Reverse(); } #endregion --- 228,232 ---- finally { ! this.pvoPositionsForOutOfSample.WeightedPositions.ReverseSigns(); } #endregion |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:24:04
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/PairsTrading/Strategies In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv11026/WalkForwardTesting/PairsTrading/Strategies Modified Files: PairsTradingIntradayStrategy.cs Log Message: An unused interval selector is handed on to the base class as intervalsSelectorForOutOfSample parameter Index: PairsTradingIntradayStrategy.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/PairsTrading/Strategies/PairsTradingIntradayStrategy.cs,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** PairsTradingIntradayStrategy.cs 28 Feb 2009 18:41:30 -0000 1.5 --- PairsTradingIntradayStrategy.cs 28 Mar 2010 15:23:56 -0000 1.6 *************** *** 71,75 **** numDaysForInSampleOptimization , intervalsSelectorForInSample , ! // intervalsSelectorForOutOfSample , eligiblesSelector , inSampleChooser , --- 71,75 ---- numDaysForInSampleOptimization , intervalsSelectorForInSample , ! intervalsSelectorForInSample , // this parameter should be intervalsSelectorForOutOfSample, but it is not going to be used by this strategy eligiblesSelector , inSampleChooser , |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:19:28
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/PairsTrading/InSample/InSampleChoosers/Genetic In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv9381/WalkForwardTesting/PairsTrading/InSample/InSampleChoosers/Genetic Modified Files: PairsTradingGeneticChooser.cs Log Message: The protecter member this.seedForRandomGenerator is now this.seedForRandomGeneratorForTheGeneticOptimizer Index: PairsTradingGeneticChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/PairsTrading/InSample/InSampleChoosers/Genetic/PairsTradingGeneticChooser.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** PairsTradingGeneticChooser.cs 30 Aug 2009 21:33:46 -0000 1.3 --- PairsTradingGeneticChooser.cs 28 Mar 2010 15:19:20 -0000 1.4 *************** *** 82,86 **** this.fitnessEvaluator , GenomeManagerType.ShortAndLong , ! this.seedForRandomGenerator ); return genomeManagerWithDuplicateGenes; } --- 82,86 ---- this.fitnessEvaluator , GenomeManagerType.ShortAndLong , ! this.seedForRandomGeneratorForTheGeneticOptimizer ); return genomeManagerWithDuplicateGenes; } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:19:11
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv9104/TickerSelectionTesting/OTC/InSampleChoosers/Genetic Modified Files: OTCFitnessEvaluator.cs Log Message: IReturnsManager is now used, instead of ReturnsManager Index: OTCFitnessEvaluator.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic/OTCFitnessEvaluator.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** OTCFitnessEvaluator.cs 31 Aug 2009 20:40:29 -0000 1.1 --- OTCFitnessEvaluator.cs 28 Mar 2010 15:19:02 -0000 1.2 *************** *** 57,61 **** private float getFitnessValue_getFitnessValueActually( ! TestingPositions testingPositions, ReturnsManager returnsManager ) { float fitnessValue; --- 57,61 ---- private float getFitnessValue_getFitnessValueActually( ! TestingPositions testingPositions, IReturnsManager returnsManager ) { float fitnessValue; *************** *** 76,80 **** } ! public double GetFitnessValue(object meaning , ReturnsManager returnsManager ) { float fitnessValue = -0.5f; --- 76,80 ---- } ! public double GetFitnessValue(object meaning , IReturnsManager returnsManager ) { float fitnessValue = -0.5f; |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:19:10
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/PairsTrading/InSample In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv9104/WalkForwardTesting/PairsTrading/InSample Modified Files: PairsTradingFitnessEvaluator.cs Log Message: IReturnsManager is now used, instead of ReturnsManager Index: PairsTradingFitnessEvaluator.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/PairsTrading/InSample/PairsTradingFitnessEvaluator.cs,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** PairsTradingFitnessEvaluator.cs 29 Sep 2008 21:20:46 -0000 1.5 --- PairsTradingFitnessEvaluator.cs 28 Mar 2010 15:19:02 -0000 1.6 *************** *** 85,89 **** private double getFitnessValue( WeightedPosition firstPosition , WeightedPosition secondPosition , ! ReturnsManager returnsManager ) { float[] firstPositionReturns = --- 85,89 ---- private double getFitnessValue( WeightedPosition firstPosition , WeightedPosition secondPosition , ! IReturnsManager returnsManager ) { float[] firstPositionReturns = *************** *** 105,109 **** private double getFitnessValue( ! WeightedPositions weightedPositions , ReturnsManager returnsManager ) { this.getFitnessValue_checkWeightedPositions( weightedPositions ); --- 105,109 ---- private double getFitnessValue( ! WeightedPositions weightedPositions , IReturnsManager returnsManager ) { this.getFitnessValue_checkWeightedPositions( weightedPositions ); *************** *** 115,119 **** } private double getFitnessValue( TestingPositions testingPositions , ! ReturnsManager returnsManager ) { double fitnessValue; --- 115,119 ---- } private double getFitnessValue( TestingPositions testingPositions , ! IReturnsManager returnsManager ) { double fitnessValue; *************** *** 135,139 **** return fitnessValue; } ! public double GetFitnessValue( object meaning , ReturnsManager returnsManager ) { this.getFitnessValue_checkParameters( meaning ); --- 135,139 ---- return fitnessValue; } ! public double GetFitnessValue( object meaning , IReturnsManager returnsManager ) { this.getFitnessValue_checkParameters( meaning ); |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:18:34
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv8754/TickerSelectionTesting/OTC/InSampleChoosers/Genetic Modified Files: OTCEndOfDayGeneticChooserWithWeights.cs Log Message: The protecter member this.seedForRandomGenerator is now this.seedForRandomGeneratorForTheGeneticOptimizer Index: OTCEndOfDayGeneticChooserWithWeights.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic/OTCEndOfDayGeneticChooserWithWeights.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** OTCEndOfDayGeneticChooserWithWeights.cs 30 Oct 2009 23:13:22 -0000 1.1 --- OTCEndOfDayGeneticChooserWithWeights.cs 28 Mar 2010 15:18:26 -0000 1.2 *************** *** 73,77 **** this.decoderForTestingPositions, this.fitnessEvaluator, this.genomeManagerType , returnsManager, ! this.seedForRandomGenerator); } } --- 73,77 ---- this.decoderForTestingPositions, this.fitnessEvaluator, this.genomeManagerType , returnsManager, ! this.seedForRandomGeneratorForTheGeneticOptimizer); } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:18:23
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv8671/TickerSelectionTesting/OTC/InSampleChoosers/Genetic Modified Files: OTCEndOfDayGeneticChooser.cs Log Message: The protecter member this.seedForRandomGenerator is now this.seedForRandomGeneratorForTheGeneticOptimizer Index: OTCEndOfDayGeneticChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic/OTCEndOfDayGeneticChooser.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** OTCEndOfDayGeneticChooser.cs 31 Aug 2009 20:40:29 -0000 1.1 --- OTCEndOfDayGeneticChooser.cs 28 Mar 2010 15:18:15 -0000 1.2 *************** *** 81,85 **** this.decoderForTestingPositions, this.fitnessEvaluator, this.genomeManagerType , returnsManager, ! this.seedForRandomGenerator); } } --- 81,85 ---- this.decoderForTestingPositions, this.fitnessEvaluator, this.genomeManagerType , returnsManager, ! this.seedForRandomGeneratorForTheGeneticOptimizer); } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:18:09
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv8494/TickerSelectionTesting/OTC/InSampleChoosers/Genetic Modified Files: OTCCTOFitnessEvaluator.cs Log Message: IReturnsManager is now used, instead of ReturnsManager Index: OTCCTOFitnessEvaluator.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/OTC/InSampleChoosers/Genetic/OTCCTOFitnessEvaluator.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** OTCCTOFitnessEvaluator.cs 31 Aug 2009 20:40:29 -0000 1.1 --- OTCCTOFitnessEvaluator.cs 28 Mar 2010 15:18:00 -0000 1.2 *************** *** 58,62 **** private float getFitnessValue_getFitnessValueActually( ! TestingPositions testingPositions, ReturnsManager returnsManager ) { float fitnessValue; --- 58,62 ---- private float getFitnessValue_getFitnessValueActually( ! TestingPositions testingPositions, IReturnsManager returnsManager ) { float fitnessValue; *************** *** 73,77 **** } ! public double GetFitnessValue(object meaning , ReturnsManager returnsManager ) { float fitnessValue = -0.5f; --- 73,77 ---- } ! public double GetFitnessValue(object meaning , IReturnsManager returnsManager ) { float fitnessValue = -0.5f; |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:17:51
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/LinearCombination In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv8398/WalkForwardTesting/LinearCombination Modified Files: LinearCombinationTest.cs Log Message: The code has been changed because now WeightedPositions is a List<WeightedPosition>, while in the previous version they it was a SortedList Index: LinearCombinationTest.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/LinearCombination/LinearCombinationTest.cs,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** LinearCombinationTest.cs 22 Nov 2008 18:22:04 -0000 1.15 --- LinearCombinationTest.cs 28 Mar 2010 15:17:43 -0000 1.16 *************** *** 306,310 **** WeightedPositions weightedPositions , Color color , Report report ) { ! foreach(WeightedPosition position in weightedPositions.Values) { WeightedPositions wp = new WeightedPositions(new SignedTickers( --- 306,310 ---- WeightedPositions weightedPositions , Color color , Report report ) { ! foreach(WeightedPosition position in weightedPositions) { WeightedPositions wp = new WeightedPositions(new SignedTickers( |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:16:14
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/LinearCombination In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv7733/WalkForwardTesting/LinearCombination Modified Files: ImmediateTrendFollowerStrategy.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: ImmediateTrendFollowerStrategy.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/LinearCombination/ImmediateTrendFollowerStrategy.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** ImmediateTrendFollowerStrategy.cs 29 Sep 2008 21:19:30 -0000 1.4 --- ImmediateTrendFollowerStrategy.cs 28 Mar 2010 15:16:06 -0000 1.5 *************** *** 103,107 **** else//the portfolio had a loss for the last half period { ! this.chosenWeightedPositions.Reverse(); //short the portfolio try{this.openPositions();} --- 103,107 ---- else//the portfolio had a loss for the last half period { ! this.chosenWeightedPositions.ReverseSigns(); //short the portfolio try{this.openPositions();} *************** *** 110,114 **** string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! finally{this.chosenWeightedPositions.Reverse();} } } --- 110,114 ---- string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! finally{this.chosenWeightedPositions.ReverseSigns();} } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:16:01
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/FixedLengthTwoPhases/InSampleChoosers/Genetic In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv7632/WalkForwardTesting/FixedLengthTwoPhases/InSampleChoosers/Genetic Modified Files: FixedLengthTwoPhasesGeneticChooser.cs Log Message: The protecter member this.seedForRandomGenerator is now this.seedForRandomGeneratorForTheGeneticOptimizer Index: FixedLengthTwoPhasesGeneticChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/FixedLengthTwoPhases/InSampleChoosers/Genetic/FixedLengthTwoPhasesGeneticChooser.cs,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** FixedLengthTwoPhasesGeneticChooser.cs 30 Aug 2009 21:33:46 -0000 1.9 --- FixedLengthTwoPhasesGeneticChooser.cs 28 Mar 2010 15:15:53 -0000 1.10 *************** *** 88,92 **** this.fitnessEvaluator , GenomeManagerType.ShortAndLong , ! this.seedForRandomGenerator ); return genomeManagerWithDuplicateGenes; } --- 88,92 ---- this.fitnessEvaluator , GenomeManagerType.ShortAndLong , ! this.seedForRandomGeneratorForTheGeneticOptimizer ); return genomeManagerWithDuplicateGenes; } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:15:13
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/FixedLengthTwoPhases/InSampleChoosers In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv7286/WalkForwardTesting/FixedLengthTwoPhases/InSampleChoosers Modified Files: FixedLengthTwoPhasesFitnessEvaluator.cs Log Message: IReturnsManager is now used, instead of ReturnsManager Index: FixedLengthTwoPhasesFitnessEvaluator.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/FixedLengthTwoPhases/InSampleChoosers/FixedLengthTwoPhasesFitnessEvaluator.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** FixedLengthTwoPhasesFitnessEvaluator.cs 29 Sep 2008 21:18:43 -0000 1.4 --- FixedLengthTwoPhasesFitnessEvaluator.cs 28 Mar 2010 15:15:05 -0000 1.5 *************** *** 91,95 **** } private double getFitnessValue( ! WeightedPositions weightedPositions , ReturnsManager returnsManager ) { float[] weightedPositionsReturns = --- 91,95 ---- } private double getFitnessValue( ! WeightedPositions weightedPositions , IReturnsManager returnsManager ) { float[] weightedPositionsReturns = *************** *** 102,106 **** } private double getFitnessValue( TestingPositions testingPositions , ! ReturnsManager returnsManager ) { double fitnessValue; --- 102,106 ---- } private double getFitnessValue( TestingPositions testingPositions , ! IReturnsManager returnsManager ) { double fitnessValue; *************** *** 117,121 **** } ! public double GetFitnessValue( object meaning , ReturnsManager returnsManager ) { this.getFitnessValue_checkParameters( meaning ); --- 117,121 ---- } ! public double GetFitnessValue( object meaning , IReturnsManager returnsManager ) { this.getFitnessValue_checkParameters( meaning ); |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:14:53
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/LinearCombination In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv7145/WalkForwardTesting/LinearCombination Modified Files: ExtremeCounterTrendStrategy.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: ExtremeCounterTrendStrategy.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/WalkForwardTesting/LinearCombination/ExtremeCounterTrendStrategy.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** ExtremeCounterTrendStrategy.cs 29 Sep 2008 21:18:42 -0000 1.7 --- ExtremeCounterTrendStrategy.cs 28 Mar 2010 15:14:45 -0000 1.8 *************** *** 105,109 **** //if gain of the last half period is positive { ! this.weightedPositions.Reverse(); //short the portfolio (short --> long; long --> short) try{ --- 105,109 ---- //if gain of the last half period is positive { ! this.weightedPositions.ReverseSigns(); //short the portfolio (short --> long; long --> short) try{ *************** *** 115,119 **** } finally{ ! this.weightedPositions.Reverse(); } } --- 115,119 ---- } finally{ ! this.weightedPositions.ReverseSigns(); } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:14:06
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv6758/TickerSelectionTesting Modified Files: EndOfDayTimerHandlerOTCCTO.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: EndOfDayTimerHandlerOTCCTO.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TickerSelectionTesting/EndOfDayTimerHandlerOTCCTO.cs,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** EndOfDayTimerHandlerOTCCTO.cs 29 Sep 2008 21:17:53 -0000 1.10 --- EndOfDayTimerHandlerOTCCTO.cs 28 Mar 2010 15:13:58 -0000 1.11 *************** *** 89,93 **** AccountManager.ClosePositions(this.account); try{ ! this.chosenWeightedPositions.Reverse(); this.openPositions(); } --- 89,93 ---- AccountManager.ClosePositions(this.account); try{ ! this.chosenWeightedPositions.ReverseSigns(); this.openPositions(); } *************** *** 96,100 **** string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! this.chosenWeightedPositions.Reverse(); } --- 96,100 ---- string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! this.chosenWeightedPositions.ReverseSigns(); } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:14:06
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv6758/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator Modified Files: EndOfDayTimerHandlerPVO.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: EndOfDayTimerHandlerPVO.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/EndOfDayTimerHandlerPVO.cs,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** EndOfDayTimerHandlerPVO.cs 29 Sep 2008 21:17:25 -0000 1.11 --- EndOfDayTimerHandlerPVO.cs 28 Mar 2010 15:13:58 -0000 1.12 *************** *** 199,203 **** this.portfolioType == PortfolioType.ShortAndLong) { ! this.chosenWeightedPositions.Reverse(); try { --- 199,203 ---- this.portfolioType == PortfolioType.ShortAndLong) { ! this.chosenWeightedPositions.ReverseSigns(); try { *************** *** 214,218 **** finally { ! this.chosenWeightedPositions.Reverse(); } } --- 214,218 ---- finally { ! this.chosenWeightedPositions.ReverseSigns(); } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:13:46
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/ExtremeCounterTrend In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv6631/TechnicalAnalysisTesting/Oscillators/ExtremeCounterTrend Modified Files: EndOfDayTimerHandlerECT.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: EndOfDayTimerHandlerECT.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/ExtremeCounterTrend/EndOfDayTimerHandlerECT.cs,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** EndOfDayTimerHandlerECT.cs 29 Sep 2008 21:17:25 -0000 1.10 --- EndOfDayTimerHandlerECT.cs 28 Mar 2010 15:13:37 -0000 1.11 *************** *** 149,153 **** this.portfolioType == PortfolioType.ShortAndLong) { ! this.chosenWeightedPositions.Reverse(); //short the portfolio try{ --- 149,153 ---- this.portfolioType == PortfolioType.ShortAndLong) { ! this.chosenWeightedPositions.ReverseSigns(); //short the portfolio try{ *************** *** 160,164 **** } finally{ ! this.chosenWeightedPositions.Reverse(); } } --- 160,164 ---- } finally{ ! this.chosenWeightedPositions.ReverseSigns(); } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:13:29
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/BiasedPVO In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv6522/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/BiasedPVO Modified Files: EndOfDayTimerHandlerBiasedPVO.cs Log Message: Code changed because WeightedPositions.Reverse() has now become WeightedPositions.ReverseSigns() Index: EndOfDayTimerHandlerBiasedPVO.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/BiasedPVO/EndOfDayTimerHandlerBiasedPVO.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** EndOfDayTimerHandlerBiasedPVO.cs 29 Sep 2008 21:18:34 -0000 1.7 --- EndOfDayTimerHandlerBiasedPVO.cs 28 Mar 2010 15:13:21 -0000 1.8 *************** *** 381,385 **** (this.portfolioType == PortfolioType.ShortAndLong || this.portfolioType == PortfolioType.OnlyMixed) ) { ! this.weightedPositionsToEvaluateOutOfSample[this.currentGenomeIndex].Reverse(); try{ this.openPositions_open(weightedPositionsToEvaluateOutOfSample[this.currentGenomeIndex],true); --- 381,385 ---- (this.portfolioType == PortfolioType.ShortAndLong || this.portfolioType == PortfolioType.OnlyMixed) ) { ! this.weightedPositionsToEvaluateOutOfSample[this.currentGenomeIndex].ReverseSigns(); try{ this.openPositions_open(weightedPositionsToEvaluateOutOfSample[this.currentGenomeIndex],true); *************** *** 390,394 **** } finally{ ! this.weightedPositionsToEvaluateOutOfSample[this.currentGenomeIndex].Reverse(); } } --- 390,394 ---- } finally{ ! this.weightedPositionsToEvaluateOutOfSample[this.currentGenomeIndex].ReverseSigns(); } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 15:07:20
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/General/Strategies/Optimizing/FitnessEvaluation In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv4251/General/Strategies/Optimizing/FitnessEvaluation Modified Files: DummyRandomFitnessEvaluator.cs Log Message: IReturnsManager is now used, instead of ReturnsManager Index: DummyRandomFitnessEvaluator.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/General/Strategies/Optimizing/FitnessEvaluation/DummyRandomFitnessEvaluator.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** DummyRandomFitnessEvaluator.cs 30 Aug 2009 22:05:54 -0000 1.1 --- DummyRandomFitnessEvaluator.cs 28 Mar 2010 15:07:12 -0000 1.2 *************** *** 46,50 **** { } ! public double GetFitnessValue(object meaning , ReturnsManager returnsManager ) { Random rnd = new Random(59); --- 46,50 ---- { } ! public double GetFitnessValue(object meaning , IReturnsManager returnsManager ) { Random rnd = new Random(59); |
|
From: Glauco S. <gla...@us...> - 2010-03-28 14:39:28
|
Update of /cvsroot/quantproject/QuantProject/b4_Business/a2_Strategies/OutOfSample In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv26756/a2_Strategies/OutOfSample Modified Files: TestingPositions.cs Log Message: If the weightedPositions are null then hashCodeForTickerComposition is the empty string Index: TestingPositions.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a2_Strategies/OutOfSample/TestingPositions.cs,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** TestingPositions.cs 30 Aug 2009 15:58:30 -0000 1.5 --- TestingPositions.cs 28 Mar 2010 14:39:20 -0000 1.6 *************** *** 19,23 **** along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ! */ using System; --- 19,23 ---- along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ! */ using System; *************** *** 28,50 **** namespace QuantProject.Business.Strategies.OutOfSample { ! /// <summary> ! /// This is the base class representing positions that ! /// should be tested out of sample in a back test ! /// Every strategy should test out of sample an object ! /// of this type or an object derived from this class ! /// </summary> ! [Serializable] ! public class TestingPositions ! { ! private WeightedPositions weightedPositions; ! private string hashCodeForTickerComposition; ! private string hashCode; ! private double fitnessInSample; ! public WeightedPositions WeightedPositions { get{return this.weightedPositions;} } ! public double FitnessInSample { get{return this.fitnessInSample;} --- 28,50 ---- namespace QuantProject.Business.Strategies.OutOfSample { ! /// <summary> ! /// This is the base class representing positions that ! /// should be tested out of sample in a back test ! /// Every strategy should test out of sample an object ! /// of this type or an object derived from this class ! /// </summary> ! [Serializable] ! public class TestingPositions ! { ! private WeightedPositions weightedPositions; ! private string hashCodeForTickerComposition; ! private string hashCode; ! private double fitnessInSample; ! public WeightedPositions WeightedPositions { get{return this.weightedPositions;} } ! public double FitnessInSample { get{return this.fitnessInSample;} *************** *** 53,162 **** public string HashCodeForTickerComposition ! { ! get ! { ! if(this.hashCodeForTickerComposition == null && ! this.weightedPositions != null) ! //if hashCodeForTickerComposition has not been computed yet and ! //the current instance is not empty ! { ! ArrayList listOfTickers = ! new ArrayList(this.weightedPositions.SignedTickers.Tickers); ! listOfTickers.Sort(); ! foreach(string tickerCode in listOfTickers) ! this.hashCodeForTickerComposition += tickerCode + ";"; ! } ! return this.hashCodeForTickerComposition; } ! } /// <summary> ! /// Hash code for the current instance ! /// Two instances have the same Hash code iif ! /// they have the same tickers with the same signed weights ! /// </summary> public string HashCode ! { ! get ! { ! if(this.hashCode == null && ! this.weightedPositions != null) ! //if hashCode has not been computed yet and ! //the current instance is not empty ! { ! ArrayList listOfTickers = ! new ArrayList(this.weightedPositions.SignedTickers.Tickers); ! listOfTickers.Sort(); ! foreach(string tickerCode in listOfTickers) ! this.hashCode += ! tickerCode + "_" + ! this.weightedPositions.GetWeightedPosition(tickerCode).Weight.ToString() + ! ";"; ! } ! return this.hashCode; } ! } public bool OnlyLongPositions ! { ! get ! { ! bool returnValue = false; ! int numOfWeightedPositions = this.weightedPositions.Count; ! int numOfLongPositions = this.weightedPositions.NumberOfLongPositions; ! if(numOfLongPositions == numOfWeightedPositions) ! //there are only long positions ! returnValue = true; ! ! return returnValue; } ! } public bool OnlyShortPositions ! { ! get ! { ! bool returnValue = false; ! int numOfWeightedPositions = this.weightedPositions.Count; ! int numOfShortPositions = this.weightedPositions.NumberOfShortPositions; ! if(numOfShortPositions == numOfWeightedPositions) ! //there are only short positions ! returnValue = true; ! ! return returnValue; } ! } public bool BothLongAndShortPositions ! { ! get ! { ! bool returnValue = false; ! int numOfWeightedPositions = this.weightedPositions.Count; ! int numOfShortPositions = this.weightedPositions.NumberOfShortPositions; ! int numOfLongPositions = this.weightedPositions.NumberOfLongPositions; ! if(numOfShortPositions != numOfWeightedPositions && ! numOfLongPositions != numOfWeightedPositions) ! //there are both long and short positions ! returnValue = true; ! ! return returnValue; } ! } public TestingPositions(WeightedPositions weightedPositions) ! { ! this.weightedPositions = weightedPositions; ! this.fitnessInSample = double.MinValue; ! } public TestingPositions(WeightedPositions weightedPositions, double fitnessInSample) ! { ! this.weightedPositions = weightedPositions; ! this.fitnessInSample = fitnessInSample; ! } //it creates an empty TestingPositions public TestingPositions() ! { ! this.weightedPositions = null; ! this.fitnessInSample = double.MinValue; } } --- 53,168 ---- public string HashCodeForTickerComposition ! { ! get ! { ! if ( this.hashCodeForTickerComposition == null ) ! { ! if ( this.weightedPositions != null) ! //if hashCodeForTickerComposition has not been computed yet and ! //the current instance is not empty ! { ! ArrayList listOfTickers = ! new ArrayList(this.weightedPositions.SignedTickers.Tickers); ! listOfTickers.Sort(); ! foreach(string tickerCode in listOfTickers) ! this.hashCodeForTickerComposition += tickerCode + ";"; ! } ! else ! // hashCodeForTickerComposition has not been computed yet, but ! // the current instance is empty ! this.hashCodeForTickerComposition = ""; ! } ! return this.hashCodeForTickerComposition; } ! } /// <summary> ! /// Hash code for the current instance ! /// Two instances have the same Hash code iif ! /// they have the same tickers with the same signed weights ! /// </summary> public string HashCode ! { ! get ! { ! if(this.hashCode == null && ! this.weightedPositions != null) ! //if hashCode has not been computed yet and ! //the current instance is not empty ! { ! ArrayList listOfTickers = ! new ArrayList(this.weightedPositions.SignedTickers.Tickers); ! listOfTickers.Sort(); ! foreach(string tickerCode in listOfTickers) ! this.hashCode += ! tickerCode + "_" + ! this.weightedPositions.GetWeightedPosition(tickerCode).Weight.ToString() + ! ";"; ! } ! return this.hashCode; } ! } public bool OnlyLongPositions ! { ! get ! { ! bool returnValue = false; ! int numOfWeightedPositions = this.weightedPositions.Count; ! int numOfLongPositions = this.weightedPositions.NumberOfLongPositions; ! if(numOfLongPositions == numOfWeightedPositions) ! //there are only long positions ! returnValue = true; ! ! return returnValue; } ! } public bool OnlyShortPositions ! { ! get ! { ! bool returnValue = false; ! int numOfWeightedPositions = this.weightedPositions.Count; ! int numOfShortPositions = this.weightedPositions.NumberOfShortPositions; ! if(numOfShortPositions == numOfWeightedPositions) ! //there are only short positions ! returnValue = true; ! ! return returnValue; } ! } public bool BothLongAndShortPositions ! { ! get ! { ! bool returnValue = false; ! int numOfWeightedPositions = this.weightedPositions.Count; ! int numOfShortPositions = this.weightedPositions.NumberOfShortPositions; ! int numOfLongPositions = this.weightedPositions.NumberOfLongPositions; ! if(numOfShortPositions != numOfWeightedPositions && ! numOfLongPositions != numOfWeightedPositions) ! //there are both long and short positions ! returnValue = true; ! ! return returnValue; } ! } public TestingPositions(WeightedPositions weightedPositions) ! { ! this.weightedPositions = weightedPositions; ! this.fitnessInSample = double.MinValue; ! } public TestingPositions(WeightedPositions weightedPositions, double fitnessInSample) ! { ! this.weightedPositions = weightedPositions; ! this.fitnessInSample = fitnessInSample; ! } //it creates an empty TestingPositions public TestingPositions() ! { ! this.weightedPositions = null; ! this.fitnessInSample = double.MinValue; } } |
|
From: Glauco S. <gla...@us...> - 2010-03-28 14:35:56
|
Update of /cvsroot/quantproject/QuantProject/b4_Business/a2_Strategies In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv25874/a2_Strategies Modified Files: SignedTickers.cs Log Message: A new constructor SignedTickers( SignedTicker[] signedTickers ) has been added Index: SignedTickers.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a2_Strategies/SignedTickers.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** SignedTickers.cs 1 Sep 2007 14:21:34 -0000 1.4 --- SignedTickers.cs 28 Mar 2010 14:35:48 -0000 1.5 *************** *** 91,94 **** --- 91,99 ---- this.addSignedTickers( signedTickers ); } + public SignedTickers( SignedTicker[] signedTickers ) + { + foreach ( SignedTicker signedTicker in signedTickers ) + this.Add( signedTicker ); + } private void addSignedTickers( string signedTickers ) { |