drilonhametaj
drilonhametaj's avatar

Info

Username:drilonhametaj
Name:drilonhametaj
Member since: 22 Dec 2022

About

None

Signature

None

Last Forum Posts

@Bring in other time series to a bot:  22 Dec 2022, 19:27


Hi, i had the same problem but i found a solution using 

 MarketData.GetBars(TimeFrame.Daily)

Then you can use this bars as Source for your indicators, i will put here an example for using it:

 protected override void OnStart()
        {
            // Put your initialization logic here
            timeFrameDaily = MarketData.GetBars(TimeFrame.Daily);
            timeFrameWeekly = MarketData.GetBars(TimeFrame.Weekly);
            timeFrameMonthly = MarketData.GetBars(TimeFrame.Monthly);
            
        }

        protected override void OnTick()
        {
            // Put your core logic here
            emaDaily = Indicators.ExponentialMovingAverage(timeFrameDaily.ClosePrices, fastPeriod);
            emaWeekly= Indicators.ExponentialMovingAverage(timeFrameWeekly.ClosePrices, midPeriod);
            emaMonthly = Indicators.ExponentialMovingAverage(timeFrameMonthly.ClosePrices, slowPeriod);

In this example i use 3 EMA with different timeframe, in backtesting this will kill the performance, need a lot of time for backtesting

Notification Publishing copyrighted material is strictly prohibited. If you believe there is copyrighted material in this section you may use the Copyright Infringement Notification form to submit a claim.

No uploaded.

Warning! Executing cBots downloaded from this section may result in loss of funds. Use them at your own risk.
Progressive Stoch
  1
  5
  379
free  22 Dec 2022
- This cBots works with EURUSD, AUDUSD, EURAUD, EURGBP, GBPUSD, NZDUSD, USDCAD, USDCHF, USDJPY - TimeFrame 4h - Not use StopLoss and for this reason you need to set lots carefully Here some example screen of backtesting   Here the settings EurUsd takeProfit: 15 stopLoss: 100000 hourEnter: 2 hourExit: 23 fastPeriod: 55 slowPeriod: 250 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 19 stochParams: 2 AudUsd takeProfit: 7 stopLoss: 100000 hourEnter: 5 hourExit: 19 fastPeriod: 45 slowPeriod: 210 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 16 stochParams: 2 EurAud takeProfit: 31 stopLoss: 100000 hourEnter: 6 hourExit: 20 fastPeriod: 65 slowPeriod: 250 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 23 stochParams: 6 EurGbp takeProfit: 19 stopLoss: 100000 hourEnter: 2 hourExit: 23 fastPeriod: 45 slowPeriod: 260 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 7 stochParams: 2 GbpUsd takeProfit: 15 stopLoss: 100000 hourEnter: 0 hourExit: 21 fastPeriod: 45 slowPeriod: 110 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 9 stochParams: 3 NzdUsd takeProfit: 9 stopLoss: 100000 hourEnter: 9 hourExit: 23 fastPeriod: 20 slowPeriod: 210 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 19 stochParams: 3 UsdCad takeProfit: 11 stopLoss: 100000 hourEnter: 9 hourExit: 18 fastPeriod: 25 slowPeriod: 240 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 24 stochParams: 3 UsdChf takeProfit: 17 stopLoss: 100000 hourEnter: 8 hourExit: 19 fastPeriod: 45 slowPeriod: 260 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 17 stochParams: 5 UsdJpy takeProfit: 8 stopLoss: 100000 hourEnter: 4 hourExit: 17 fastPeriod: 50 slowPeriod: 130 lots: check in lots section maxOrder: 2 (depends how many MAX orders you want to have open in the same time) stochLength: 15 stochParams: 3 Lots to use by your account balance: from: 100$  to: 500$  use 0.01 lots from: 500$  to: 1.000$  use 0.03 lots   from: 1.000$  to: 2.000$  use 0.06 lots from: 2.000$  to: 5.000$  use 0.1 lots from: 5.000$  to: 10.000$  use 0.3 lots from: 10.000$  to: 15.000$  use 0.5 lots from: 15.000$  to: 20.000$  use 1 lots  from: 20.000$ + use 2 lots  and add 1 lot for each 10k   To respect this rules it's important for your money management! Don't rush, let the money work for you!