protected override void Init() { _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); // _stoInd= GetIndicator<StochasticOscillator>(Instrument.Id, Timeframe); _wprInd = GetIndicator <ZigZag>(Instrument.Id, Timeframe); _wprInd.ExtDepth = 6; }
protected override void Init() { _frInd = GetIndicator <Fractals>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); Ur1 = 10.0; Ur2 = 0.0; }
protected override void Init() { // Event occurs once at the start of the strategy Print("Starting TS on account: {0}, comment: {1}", this.Account.Number, CommentText); _stoInd = GetIndicator <StochasticOscillator>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); }
protected override void Init() { Print("LR_Trade_strategy_initalization"); //Print("Period = {0}", Period); //Print("Ma1Period = ",Ma1Period); //Print("Ma2Period = ",Ma1Period); if ((LotVolume > Account.MaxLot) || (LotVolume < Account.MinLot)) { Print("LR_Invalid_lot_value"); Print("LR_Lot_minimum_value " + (double)Account.MinLot); Print("LR_Lot_maximum_value " + (double)Account.MaxLot); _isAnyErrors = true; return; } var _instrumentId = this.Instrument.Id; _period = Timeframe; // Период берется текущий - Н1 //Print("_period = {0} " ,_period); //_macd = GetIndicator<FisherTransformOscillator>(Instrument.Id, _period, FastEMA, SlowEMA, MacdSMA, PositionPriceMode); // Створити індикатор //_macd = GetIndicator<FisherTransformOscillator>(Instrument.Id, _period, Ma1Period, Ma2Method, Ma2Method); _macd = GetIndicator <FisherTransformOscillator>(Instrument.Id, _period); _barSeries = GetCustomSeries(Instrument.Id, _period); // Номер текущего бара // Print("_barSeries = {0} " ,_barSeries.Range.To); }
protected override void Init() { // Event occurs once at the start of the strategy #region GetIndicatorsAndFrames // Get Indicators' references... Print("Starting TS on account: {0} ", this.Account.Number); InitLogFile(); _period = Timeframe; _barSeries = GetCustomSeries(Instrument.Id, _period); FTOind = GetIndicator <FisherTransformOscillator>( Instrument.Id, _period, FisherPeriod, FisherMa1Period, FisherMa1Method, FisherMa2Period, FisherMa2Method); EnvindTP = GetIndicator <Envelopes>( Instrument.Id, _period, envelopesTPperiod, envelopesTPdev, envelopesTPshift, envelopesTPmethod, envelopesTPprice); #endregion //GetIndicatorsAndFrames // Print("Starting TS on account: {0}, comment: {1}", this.Account.Number, CommentText); }
protected override void Init() { FsU = false; FsD = false; dlt = dl * Instrument.Point; _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); }
protected override void Init() { _wprInd = GetIndicator <ZigZag>(Instrument.Id, Timeframe); _wprInd.ExtDepth = ED; _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); _ftoInd.Ma2Period = 34; }
protected override void Init() { _frInd = GetIndicator <Fractals>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); _wprInd = GetIndicator <ZigZag>(Instrument.Id, Timeframe); _wprInd.ExtDepth = 3; }
public DateTime DTime; // Время protected override void Init() { InitLogFile(); #region GetIndicatorsAndFrames// Get Indicators' references... // Event occurs once at the start of the strategy //XXPrint("Starting TS on account: {0}, comment: {1}, buystop : {2} sellstop : {3}", // this.Account.Number, "CommentText", listOfBuyStop.Count, listOfSellStop.Count); Print("Starting TS on account: {0}, comment: {1}", this.Account.Number, CommentText); _ma1 = GetIndicator <MovingAverage>(Instrument.Id, Timeframe, 85, 0, MethodMA1, ApplyMA1To); _ma2 = GetIndicator <MovingAverage>(Instrument.Id, Timeframe, 75, 0, MethodMA1, ApplyMA1To); _ma3 = GetIndicator <MovingAverage>(Instrument.Id, Timeframe, 5, 0, MethodMA2, ApplyMA2To); _macd = GetIndicator <MovingAverageConvergenceDivergence> (Instrument.Id, Timeframe); _macd.FastEmaPeriod = 15; _macd.AppliedPrice = ApplyMA2To; _macd.SlowEmaPeriod = 26; _macd.SmaPeriod = 1; _awoInd = GetIndicator <AwesomeOscillator>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); _frInd = GetIndicator <Fractals>(Instrument.Id, Timeframe); #endregion //GetIndicatorsAndFrames }
protected override void Init() { nu=false; nd=false; md=0; mu=0; InitFile(); if(_ftoInd==null) _ftoInd = GetIndicator<FisherTransformOscillator>(Instrument.Id, Timeframe); // Рисуем зоны if(toolTrendLine4==null) { toolTrendLine4 = Tools.Create<TrendLine>(); toolTrendLine4.Color=Color.HotPink;toolTrendLine4.Width=3; } if(toolTrendLine2==null) { toolTrendLine2 = Tools.Create<TrendLine>(); toolTrendLine2.Color=Color.Crimson;toolTrendLine2.Width=6; } if(toolTrendLineD==null) { toolTrendLineD = Tools.Create<TrendLine>(); toolTrendLineD.Color=Color.ForestGreen;toolTrendLineD.Width=6; } // Рисуем линии волн if(toolTrendLineU1==null) { toolTrendLineU1 = Tools.Create<TrendLine>(); toolTrendLineU1.Color=Color.Aqua;toolTrendLineU1.Width=3; } if(toolTrendLineU2==null) { toolTrendLineU2 = Tools.Create<TrendLine>(); toolTrendLineU2.Color=Color.Aqua;toolTrendLineU2.Width=3; } if(toolTrendLineU3==null) { toolTrendLineU3 = Tools.Create<TrendLine>(); toolTrendLineU3.Color=Color.Aqua;toolTrendLineU3.Width=3; } if(toolTrendLineU4==null) { toolTrendLineU4 = Tools.Create<TrendLine>(); toolTrendLineU4.Color=Color.Aqua;toolTrendLineU4.Width=3; } if(toolTrendLineD1==null) { toolTrendLineD1 = Tools.Create<TrendLine>(); toolTrendLineD1.Color=Color.Aqua;toolTrendLineD1.Width=3; } if(toolTrendLineD2==null) { toolTrendLineD2 = Tools.Create<TrendLine>(); toolTrendLineD2.Color=Color.Aqua;toolTrendLineD2.Width=3; } if(toolTrendLineD3==null) { toolTrendLineD3 = Tools.Create<TrendLine>(); toolTrendLineD3.Color=Color.Aqua;toolTrendLineD3.Width=3; } if(toolTrendLineD4==null) { toolTrendLineD4 = Tools.Create<TrendLine>(); toolTrendLineD4.Color=Color.Aqua;toolTrendLineD4.Width=3; } if(toolText==null) { toolText = Tools.Create<Text>();toolText.Color=Color.Aqua; } if(toolText1==null) { toolText1 = Tools.Create<Text>();toolText1.Color=Color.Aqua; } if(tU1==null) { tU1 = Tools.Create<Text>(); tU1.Color=Color.Aqua; } if(tU2==null) { tU2 = Tools.Create<Text>(); tU2.Color=Color.Aqua; } if(tU3==null) { tU3 = Tools.Create<Text>(); tU3.Color=Color.Aqua; } if(tU4==null) { tU4 = Tools.Create<Text>(); tU4.Color=Color.Aqua; } if(tD1==null) { tD1 = Tools.Create<Text>(); tD1.Color=Color.Aqua; } if(tD2==null) { tD2 = Tools.Create<Text>(); tD2.Color=Color.Aqua; } if(tD3==null) { tD3 = Tools.Create<Text>(); tD3.Color=Color.Aqua; } if(tD4==null) { tD4 = Tools.Create<Text>(); tD4.Color=Color.Aqua; } }
protected override void Init() { // Event occurs once at the start of the strategy Print("Starting TS on account: {0}, comment: {1}", this.Account.Number, CommentText); InitLogFile(); //XXPrint("ZZ11:{0} Счет:{1} Пара:{2}",Bars[Bars.Range.To].Time, this.Account.Number,this.Instrument.Name); //XXPrint("Ордер Дата Time №Ордер Цена Left Right Delta VLeft VOrder VRight"); _wprInd = GetIndicator <ZigZag>(Instrument.Id, Timeframe); _wprInd.ExtDepth = ED; _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); if (Instrument.Name.EndsWith("JPY")) { kor2 = 0.001 * Pt; Zn = 1000; n = 3; } else { kor2 = 0.00001 * Pt; Zn = 100000; n = 5; } //_frInd = GetIndicator<Fractals>(Instrument.Id, Timeframe); vr = Tools.Create <VerticalLine>(); vr.Color = Color.Red; vb = Tools.Create <VerticalLine>(); vb.Color = Color.Blue; vy = Tools.Create <VerticalLine>(); vy.Color = Color.Yellow; vw = Tools.Create <VerticalLine>(); vw.Color = Color.MediumVioletRed; }
protected override void Init() { nu = false; nd = false; tu = false; td = false; Print("Init !!! 1"); InitFile(); _ma50 = GetIndicator <MovingAverage>(Instrument.Id, Timeframe, 50, 0, MaMethods.Ema, PriceMode.Close); _tsfInd = GetIndicator <TimeSeriesForecast>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); _frInd = GetIndicator <Fractals>(Instrument.Id, Timeframe); _frInd.Range = frac - 2; vl = Tools.Create <VerticalLine>(); vl.Width = 2; hl = Tools.Create <HorizontalLine>(); k = 0; // Для першого входження - kf = 0.090909; dlt = dl * Instrument.Point; // Отступ от стопа frU1 = 0.0; frU2 = 0.0; frU3 = 0.0; frD1 = 0.0; frD2 = 0.0; frD3 = 0.0; fsU1 = 0.0; fsU2 = 0.0; fsU3 = 0.0; fsD1 = 0.0; fsU2 = 0.0; fsU3 = 0.0; trueLogPath = PathToLogFile + "\\" + L1 + "_" + Instrument.Name.ToString() + ".LOG"; trueBuyPath = PathToLogFile + "\\01_TORG.LOG"; }
protected override void Init() { periodM15 = new Period(PeriodType.Minute, 10); _barM15 = GetCustomSeries(Instrument.Id, periodM15); _ftoIndM15 = GetIndicator <FisherTransformOscillator>(Instrument.Id, periodM15); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); }
protected override void Init() { _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); _ichInd = GetIndicator <Ichimoku>(Instrument.Id, Timeframe); _barH1 = GetCustomSeries(Instrument.Id, Period.H1); _ichIndH1 = GetIndicator <Ichimoku>(Instrument.Id, Period.H1); }
protected override void Init() { _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); _wprInd = GetIndicator <ZigZag>(Instrument.Id, Timeframe); //_wprInd.ExtDepth=5; //_wprInd.ExtDeviation=0; //_wprInd.ExtBackStep=3; }
protected override void Init() { FsU = false; FsD = false; Print("{0} Start INIT ", Bars[Bars.Range.To - 1].Time); InitLogFile(); dlt = dl * Instrument.Point; _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); }
protected override void Init() { torg = false; LogU = false; LogD = false; U1 = 100; D1 = -1; _barH1 = GetCustomSeries(Instrument.Id, Period.H1); Line1 = Tools.Create <HorizontalLine>(); Line2 = Tools.Create <HorizontalLine>(); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); _ftoIndH1 = GetIndicator <FisherTransformOscillator>(Instrument.Id, Period.H1); }
protected override void Init() { k = 0; NKZ = 560; _frInd = GetIndicator <Fractals>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); Print("Init"); k = 0; frU1 = 0; frU2 = 0; frU3 = 0; frD1 = 0; frD2 = 0; frD3 = 0; // InitFr(); }
protected override void Init() { _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); Line1 = Tools.Create <HorizontalLine>(); Line2 = Tools.Create <HorizontalLine>(); _wprInd3 = GetIndicator <ZigZag>(Instrument.Id, Timeframe); _wprInd3.ExtDepth = 3; isF = true; }
protected override void Init() { nu = false; nd = false; md = 0; mu = 0; InitFile(); if (_ftoInd == null) { _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); } }
protected override void Init() { _wprInd = GetIndicator <ZigZag>(Instrument.Id, Timeframe); _wprInd.ExtDepth = ED; _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); periodM15 = new Period(PeriodType.Minute, 15); _barM15 = GetCustomSeries(Instrument.Id, Period.H1); _ftoInd15 = GetIndicator <FisherTransformOscillator>(Instrument.Id, Period.H1); }
protected override void Init() { // Event occurs once at the start of the strategy // Вставить индикатор Alligator _allInd = GetIndicator <Alligator>(Instrument.Id, Timeframe); // Вставить индикатор Fractals _frInd = GetIndicator <Fractals>(Instrument.Id, Timeframe); _awoInd = GetIndicator <AwesomeOscillator>(Instrument.Id, Timeframe); //_aoInd = GetIndicator<AcceleratorOscillator>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); }
protected override void Init() { _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); mind = double.MaxValue; maxu = double.MinValue; fish = false; toolPolyLine = Tools.Create <PolyLine>(); toolPolyLine.Color = Color.Aqua; toolPolyLine.Width = 2; kf = 0.0; }
protected override void Init() { trueLogPath = PathToLogFile + "\\" + LogFileName + ".LOG"; _wprInd3 = GetIndicator <ZigZag>(Instrument.Id, Timeframe); _wprInd3.ExtDepth = 5; _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); vy = Tools.Create <VerticalLine>(); vy.Color = Color.Red; vb = Tools.Create <VerticalLine>(); vb.Color = Color.Blue; }
protected override void Init() { // Event occurs once at the start of the strategy Print("Starting TS on account: {0}, comment: {1}", this.Account.Number, CommentText); _stoInd = GetIndicator <StochasticOscillator>(Instrument.Id, Timeframe); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); vlR = Tools.Create <VerticalLine>(); vlR.Color = Color.Red; vlB = Tools.Create <VerticalLine>(); vlB.Color = Color.Blue; }
protected override void Init() { periodD1 = new Period(PeriodType.Day, 1); periodH4 = new Period(PeriodType.Hour, 4); _barD1 = GetCustomSeries(Instrument.Id, periodD1); _barH4 = GetCustomSeries(Instrument.Id, periodH4); _barH1 = GetCustomSeries(Instrument.Id, Period.H1); _ftoIndD1 = GetIndicator <FisherTransformOscillator>(Instrument.Id, periodD1); _ftoIndH4 = GetIndicator <FisherTransformOscillator>(Instrument.Id, periodH4); _ftoIndH1 = GetIndicator <FisherTransformOscillator>(Instrument.Id, Period.H1); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); }
protected override void Init() { // Event occurs once at the start of the strategy // На график наносится скользящая средняя с периодом 20 _ma20 = GetIndicator <MovingAverage>(Instrument.Id, Timeframe, _maPeriod20, _maShift, _maMethod, _priceMode); // На график наносится скользящая средняя с периодом 50 _ma50 = GetIndicator <MovingAverage>(Instrument.Id, Timeframe, _maPeriod50, _maShift, _maMethod, _priceMode); _frInd = GetIndicator <Fractals>(Instrument.Id, Timeframe); _barSeries = GetCustomSeries(Instrument.Id, Period.H1); _ftoIndH1 = GetIndicator <FisherTransformOscillator>(Instrument.Id, Period.H1); }
protected override void Init() { trueLogPath = PathToLogFile + "\\" + LogFileName + ".LOG"; periodM15 = new Period(PeriodType.Minute, 15); periodH4 = new Period(PeriodType.Hour, 4); _barM15 = GetCustomSeries(Instrument.Id, periodM15); _barH1 = GetCustomSeries(Instrument.Id, Period.H1); _barH4 = GetCustomSeries(Instrument.Id, periodH4); _ftoIndH4 = GetIndicator <FisherTransformOscillator>(Instrument.Id, periodH4); _ftoIndH1 = GetIndicator <FisherTransformOscillator>(Instrument.Id, Period.H1); _ftoIndM15 = GetIndicator <FisherTransformOscillator>(Instrument.Id, periodM15); _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); }
protected override void Init() { // Event occurs once at the start of the strategy Print("Starting {2} on account: {0}, comment: {1}, date: {3}", this.Account.Number, "Started!", "PAVRYKNo1", DateTime.Now); try { _barSeries = GetCustomSeries(Instrument.Id, _period); _PivotBarSeries = GetCustomSeries(Instrument.Id, _pivotPeriod); /// fisher activation FTOind = GetIndicator <FisherTransformOscillator>( Instrument.Id, _period, FisherPeriod, FisherMa1Period, FisherMa1Method, FisherMa2Period, FisherMa2Method); /// MA5 activation MA5ind = GetIndicator <MovingAverage>( Instrument.Id, _period, MA5period, MA5offset, MA5method, MA5applyto); /// MA24 activation MA24ind = GetIndicator <MovingAverage>( Instrument.Id, _period, MA24period, MA24offset, MA24method, MA24applyto); /// pivot activation Pivind = GetIndicator <Pivot>( Instrument.Id, _period); //_pivotPeriod, //96, //1440, quantity of bars in 1 day? //PivotType.Pivot); } catch (Exception ex) { Print("[*Init*]:" + ex.Message); Print("[*Init*]:" + ex.StackTrace); } CalculateSL(0); }
protected override void Init() { _ftoInd = GetIndicator <FisherTransformOscillator>(Instrument.Id, Timeframe); mind = double.MaxValue; maxu = double.MinValue; kf = 0.0; toolTrendLineU1 = Tools.Create <TrendLine>(); toolTrendLineU1.Color = Color.Aqua; toolTrendLineU1.Width = 3; toolTrendLineU2 = Tools.Create <TrendLine>(); toolTrendLineU2.Color = Color.Aqua; toolTrendLineU2.Width = 3; toolTrendLineU3 = Tools.Create <TrendLine>(); toolTrendLineU3.Color = Color.Aqua; toolTrendLineU3.Width = 3; toolTrendLineD1 = Tools.Create <TrendLine>(); toolTrendLineD1.Color = Color.Aqua; toolTrendLineD1.Width = 3; toolTrendLineD2 = Tools.Create <TrendLine>(); toolTrendLineD2.Color = Color.Aqua; toolTrendLineD2.Width = 3; toolTrendLineD3 = Tools.Create <TrendLine>(); toolTrendLineD3.Color = Color.Aqua; toolTrendLineD3.Width = 3; }