[Quantproject-developers] QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOs
Brought to you by:
glauco_1
|
From: Marco M. <mi...@us...> - 2008-08-15 00:53:06
|
Update of /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv19183/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers Modified Files: PVO_CTCCorrelationChooser.cs PVO_OTCCorrelationChooser.cs PVO_OTCCTOCorrelationChooser.cs PVOCorrelationChooser.cs Log Message: Minor changes for the some files implementing the PVO strategy Index: PVO_OTCCorrelationChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers/PVO_OTCCorrelationChooser.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** PVO_OTCCorrelationChooser.cs 26 Apr 2008 09:53:14 -0000 1.3 --- PVO_OTCCorrelationChooser.cs 14 Aug 2008 23:28:06 -0000 1.4 *************** *** 61,70 **** bool balancedWeightsOnVolatilityBase, float minimumAbsoluteReturnValue, ! float maximumAbsoluteReturnValue) : base(numberOfBestTestingPositionsToBeReturned, 1, maxCorrelationValue, balancedWeightsOnVolatilityBase, ! IntervalsType.DailyOpenToCloseIntervals) { this.minimumAbsoluteReturnValue = minimumAbsoluteReturnValue; --- 61,72 ---- bool balancedWeightsOnVolatilityBase, float minimumAbsoluteReturnValue, ! float maximumAbsoluteReturnValue, ! string benchmark) : base(numberOfBestTestingPositionsToBeReturned, 1, maxCorrelationValue, balancedWeightsOnVolatilityBase, ! IntervalsType.OpenToCloseIntervals, ! benchmark) { this.minimumAbsoluteReturnValue = minimumAbsoluteReturnValue; Index: PVOCorrelationChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers/PVOCorrelationChooser.cs,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** PVOCorrelationChooser.cs 26 Apr 2008 09:41:26 -0000 1.5 --- PVOCorrelationChooser.cs 14 Aug 2008 23:28:06 -0000 1.6 *************** *** 54,57 **** --- 54,58 ---- protected bool balancedWeightsOnVolatilityBase; protected IntervalsType intervalsType; + protected string benchmark; public virtual string Description *************** *** 78,81 **** --- 79,90 ---- } + public int ReturnIntervalLength + { + get + { + return this.numDaysForOscillatingPeriod; + } + } + /// <summary> /// PVOCorrelationChooser to be used for *************** *** 99,103 **** double maxCorrelationValue, bool balancedWeightsOnVolatilityBase, ! IntervalsType intervalsType) { this.numberOfBestTestingPositionsToBeReturned = numberOfBestTestingPositionsToBeReturned; --- 108,113 ---- double maxCorrelationValue, bool balancedWeightsOnVolatilityBase, ! IntervalsType intervalsType, ! string benchmark) { this.numberOfBestTestingPositionsToBeReturned = numberOfBestTestingPositionsToBeReturned; *************** *** 106,109 **** --- 116,120 ---- this.balancedWeightsOnVolatilityBase = balancedWeightsOnVolatilityBase; this.intervalsType = intervalsType; + this.benchmark = benchmark; } Index: PVO_OTCCTOCorrelationChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers/PVO_OTCCTOCorrelationChooser.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** PVO_OTCCTOCorrelationChooser.cs 26 Apr 2008 09:17:47 -0000 1.1 --- PVO_OTCCTOCorrelationChooser.cs 14 Aug 2008 23:28:06 -0000 1.2 *************** *** 61,70 **** bool balancedWeightsOnVolatilityBase, float minimumAbsoluteReturnValue, ! float maximumAbsoluteReturnValue) : base(numberOfBestTestingPositionsToBeReturned, 1, maxCorrelationValue, balancedWeightsOnVolatilityBase, ! IntervalsType.OpenToCloseCloseToOpenIntervals) { this.minimumAbsoluteReturnValue = minimumAbsoluteReturnValue; --- 61,72 ---- bool balancedWeightsOnVolatilityBase, float minimumAbsoluteReturnValue, ! float maximumAbsoluteReturnValue, ! string benchmark) : base(numberOfBestTestingPositionsToBeReturned, 1, maxCorrelationValue, balancedWeightsOnVolatilityBase, ! IntervalsType.OpenToCloseCloseToOpenIntervals, ! benchmark) { this.minimumAbsoluteReturnValue = minimumAbsoluteReturnValue; Index: PVO_CTCCorrelationChooser.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b7_Scripts/TechnicalAnalysisTesting/Oscillators/FixedLevelOscillators/PortfolioValueOscillator/InSampleChoosers/PVO_CTCCorrelationChooser.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** PVO_CTCCorrelationChooser.cs 26 Apr 2008 09:53:14 -0000 1.3 --- PVO_CTCCorrelationChooser.cs 14 Aug 2008 23:28:06 -0000 1.4 *************** *** 44,47 **** --- 44,52 ---- public class PVO_CTCCorrelationChooser : PVOCorrelationChooser { + private float minimumAbsoluteReturnValue; + private float maximumAbsoluteReturnValue; + //correlation is computed only for returns + //between minimum and maximum + /// <summary> /// PVO_CTCCorrelationChooser to be used for *************** *** 55,66 **** int closeToCloseReturnIntervalLength, double maxCorrelationValue, ! bool balancedWeightsOnVolatilityBase) : base(numberOfBestTestingPositionsToBeReturned, closeToCloseReturnIntervalLength, maxCorrelationValue, balancedWeightsOnVolatilityBase, ! IntervalsType.CloseToCloseIntervals_OneDay) { ! } --- 60,76 ---- int closeToCloseReturnIntervalLength, double maxCorrelationValue, ! bool balancedWeightsOnVolatilityBase, ! float minimumAbsoluteReturnValue, ! float maximumAbsoluteReturnValue, ! string benchmark) : base(numberOfBestTestingPositionsToBeReturned, closeToCloseReturnIntervalLength, maxCorrelationValue, balancedWeightsOnVolatilityBase, ! IntervalsType.CloseToCloseIntervals, ! benchmark) { ! this.minimumAbsoluteReturnValue = minimumAbsoluteReturnValue; ! this.maximumAbsoluteReturnValue = maximumAbsoluteReturnValue; } *************** *** 73,77 **** new CloseToCloseCorrelationProvider(eligibleTickers.Tickers, firstDate, lastDate, this.numDaysForOscillatingPeriod, ! 0.0001f, 0.5f, "^GSPC"); } } --- 83,89 ---- new CloseToCloseCorrelationProvider(eligibleTickers.Tickers, firstDate, lastDate, this.numDaysForOscillatingPeriod, ! this.minimumAbsoluteReturnValue, ! this.maximumAbsoluteReturnValue, ! this.benchmark); } } |