Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/WeightedPVO/WeightedBalancedPVO
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv13724/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/WeightedPVO/WeightedBalancedPVO
Modified Files:
EndOfDayTimerHandlerWeightedBalancedPVO.cs
Log Message:
Code has been re-organized in a more logical and Object Oriented way:
- WeightedPositions class has been used.
- Some static methods have been deleted from SignedTicker class. They have been moved
to WeightedPositions.
- Basic orders'management has been moved to the primitive base class EndOfDayTimerHandler
and to AccountManager class
Index: EndOfDayTimerHandlerWeightedBalancedPVO.cs
===================================================================
RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/WeightedPVO/WeightedBalancedPVO/EndOfDayTimerHandlerWeightedBalancedPVO.cs,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** EndOfDayTimerHandlerWeightedBalancedPVO.cs 9 Apr 2007 18:07:09 -0000 1.2
--- EndOfDayTimerHandlerWeightedBalancedPVO.cs 29 Aug 2007 09:50:21 -0000 1.3
***************
*** 127,131 ****
{
DataTable setOfTickersToBeOptimized = this.getSetOfTickersToBeOptimized(currentDate);
! if(setOfTickersToBeOptimized.Rows.Count > this.chosenTickers.Length*2)
//the optimization process is meaningful only if the initial set of tickers is
//larger than the number of tickers to be chosen
--- 127,131 ----
{
DataTable setOfTickersToBeOptimized = this.getSetOfTickersToBeOptimized(currentDate);
! if(setOfTickersToBeOptimized.Rows.Count > this.numberOfTickersToBeChosen*2)
//the optimization process is meaningful only if the initial set of tickers is
//larger than the number of tickers to be chosen
***************
*** 154,159 ****
GO.Run(false);
! this.chosenTickers = ((GenomeMeaningPVO)GO.BestGenome.Meaning).Tickers;
! this.chosenTickersPortfolioWeights = ((GenomeMeaningPVO)GO.BestGenome.Meaning).TickersPortfolioWeights;
this.currentOversoldThreshold = ((GenomeMeaningPVO)GO.BestGenome.Meaning).OversoldThreshold;
this.currentOverboughtThreshold = ((GenomeMeaningPVO)GO.BestGenome.Meaning).OverboughtThreshold;
--- 154,159 ----
GO.Run(false);
! this.chosenWeightedPositions = new WeightedPositions( ((GenomeMeaningPVO)GO.BestGenome.Meaning).TickersPortfolioWeights,
! new SignedTickers( ((GenomeMeaningPVO)GO.BestGenome.Meaning).Tickers) );
this.currentOversoldThreshold = ((GenomeMeaningPVO)GO.BestGenome.Meaning).OversoldThreshold;
this.currentOverboughtThreshold = ((GenomeMeaningPVO)GO.BestGenome.Meaning).OverboughtThreshold;
|