Exemplo n.º 1
0
        // Initialization

        public DowTheoryClass(NinjaScriptBase owner, DrawingProperties drawingProperties, CalculationTypeListDowTheory calculationTypeListDT,
                              CalculationTypeList calculationTypeListPCW, double strength, bool useHighLow, bool showPoints, bool showLines,
                              double maxPercentOfPivotRetraction, double minPercentOfPivotRetraction)
        {
            this.owner             = owner;
            this.drawingProperties = drawingProperties;
            CalculationType        = calculationTypeListDT;

            priceActionSwingClass = new PriceActionSwingClass(owner, drawingProperties, calculationTypeListPCW, strength,
                                                              useHighLow, showPoints, showLines);
            trendCalculation = new TrendCalculation(owner);
            pivotCalculation = new PivotCalculation(owner, maxPercentOfPivotRetraction, minPercentOfPivotRetraction);

            /*
             * if (!ShowLog)
             * {
             *  logPrinter.SetIndicatorAsInvisible(owner);
             * }
             */
        }
Exemplo n.º 2
0
 public Indicators.JiraiyaIndicators.DowTheoryIndicator DowTheoryIndicator(ISeries <double> input, CalculationTypeListDowTheory calculationTypeDT, CalculationTypeList calculationTypePCW, double strength, bool useHighLow, double maxPercentOfPivotRetraction, double minPercentOfPivotRetraction)
 {
     return(indicator.DowTheoryIndicator(input, calculationTypeDT, calculationTypePCW, strength, useHighLow, maxPercentOfPivotRetraction, minPercentOfPivotRetraction));
 }
Exemplo n.º 3
0
 public JiraiyaIndicators.DowTheoryIndicator DowTheoryIndicator(ISeries <double> input, CalculationTypeListDowTheory calculationTypeDT, CalculationTypeList calculationTypePCW, double strength, bool useHighLow, double maxPercentOfPivotRetraction, double minPercentOfPivotRetraction)
 {
     if (cacheDowTheoryIndicator != null)
     {
         for (int idx = 0; idx < cacheDowTheoryIndicator.Length; idx++)
         {
             if (cacheDowTheoryIndicator[idx] != null && cacheDowTheoryIndicator[idx].CalculationTypeDT == calculationTypeDT && cacheDowTheoryIndicator[idx].CalculationTypePCW == calculationTypePCW && cacheDowTheoryIndicator[idx].Strength == strength && cacheDowTheoryIndicator[idx].UseHighLow == useHighLow && cacheDowTheoryIndicator[idx].MaxPercentOfPivotRetraction == maxPercentOfPivotRetraction && cacheDowTheoryIndicator[idx].MinPercentOfPivotRetraction == minPercentOfPivotRetraction && cacheDowTheoryIndicator[idx].EqualsInput(input))
             {
                 return(cacheDowTheoryIndicator[idx]);
             }
         }
     }
     return(CacheIndicator <JiraiyaIndicators.DowTheoryIndicator>(new JiraiyaIndicators.DowTheoryIndicator()
     {
         CalculationTypeDT = calculationTypeDT, CalculationTypePCW = calculationTypePCW, Strength = strength, UseHighLow = useHighLow, MaxPercentOfPivotRetraction = maxPercentOfPivotRetraction, MinPercentOfPivotRetraction = minPercentOfPivotRetraction
     }, input, ref cacheDowTheoryIndicator));
 }