
Topics
Replies
PanagiotisCharalampous
23 Oct 2020, 16:47
Hi duketv,
You are probably calling the method somewhere using 2 arguments. But I am just guessing since you haven't posted the complete cBot code.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 16:02
Hi coship00,
At the moment default position size is the minimum position size.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 08:57
Hi seetame,
See here.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 08:54
Hi heliodorstar,
You could consider preprocessing the Where query and save the results in a separate list to have the positions ready when the time to close them comes.
You can also consider using Parallel.ForEach
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 08:49
Hi there,
Thanks for posting in our forum. However your post doesn't make much sense so I cannot understand what is the problem and how we can help. Could you try explaining better what is the issue?
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 08:39
Hi all,
Here you go
using System;
using cAlgo.API;
using cAlgo.API.Internals;
using cAlgo.API.Indicators;
using cAlgo.Indicators;
using System.Reflection;
using System.Linq;
namespace cAlgo
{
[Cloud("Fast MA", "Slow MA", FirstColor = "Green", Opacity = 0.5, SecondColor = "Red")]
[Indicator(IsOverlay = true, TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
public class CloudExample : Indicator
{
[Parameter("Fast MA Period", DefaultValue = 21)]
public int FastMaPeriod { get; set; }
[Parameter("Slow MA Period", DefaultValue = 50)]
public int SlowMaPeriod { get; set; }
[Output("Fast MA", LineColor = "#FF6666")]
public IndicatorDataSeries FastMaResult { get; set; }
[Output("Slow MA", LineColor = "#0071C1")]
public IndicatorDataSeries SlowMaResult { get; set; }
SimpleMovingAverage FastMa;
SimpleMovingAverage SlowMa;
protected override void Initialize()
{
FastMa = Indicators.SimpleMovingAverage(Bars.ClosePrices, FastMaPeriod);
SlowMa = Indicators.SimpleMovingAverage(Bars.ClosePrices, SlowMaPeriod);
}
public override void Calculate(int index)
{
FastMaResult[index] = FastMa.Result[index];
SlowMaResult[index] = SlowMa.Result[index];
}
}
}
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 08:37
Hi duketv,
In my second I worked with OpenPosition, but this gives me problems in the method definition. It gives the error that no method has been found to override..
Then skip the override keyword :)
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 08:30
Hi m.mohammadreza.m.s,
You can use PlotType.Points to display points on your chart. If you need to show only specific points then you can set all other values to NaN.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
23 Oct 2020, 08:03
Hi YouFX,
You can get the opening times of bars using OpenTimes time series.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
22 Oct 2020, 16:11
Hi JeanPaul,
cTrader offers you the option to backtest a cBot that places trades on multiple instruments. If you need different parameters per instrument, you need to program this yourself. The overall results will be for all the instruments you have placed trades for. If you want to backtest multiple instances at the same time, then this is not possible neither we have plans for such a feature.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
22 Oct 2020, 09:10
Hi tgjobscv,
This platform is not supported by us.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
22 Oct 2020, 08:25
Hi GinoongULap,
You can use cTrader Copy.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
22 Oct 2020, 08:23
Hi fcomanjoncabeza,
There is no difference, it is the same value.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
22 Oct 2020, 08:18
Hi plms702,
Yes it is possible. There is nothing special you need to do, just create your strategy and follow with the rest of the accounts you wish to follow.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
22 Oct 2020, 08:15
Hi m.francomano,
Yes it does. In the meanwhile, please go to C:\Users\UserName\AppData\Roaming\broker cTrader\Settings, delete the contents of the folder and let me know if this fixes the issue.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
21 Oct 2020, 16:50
Hi JeanPaul,
If you are referring to multi symbol backtesting, then yes this is already available.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
21 Oct 2020, 14:21
Hi m.francomano,
We have received the error report and the team is working on a fix.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
21 Oct 2020, 14:12
Hi lohzi97,
This seems to be a bug. I reported this to the product team and will be fixed in a future update. The correct values are the ones printed by the cBot.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
21 Oct 2020, 12:09
Hi duketv,
The answer is in the documentation. This method is a member of the Position class.
Best Regards,
Panagiotis
@PanagiotisCharalampous
PanagiotisCharalampous
26 Oct 2020, 07:51
Hi duketv,
Thanks, I was correct then.
Best Regards,
Panagiotis
Join us on Telegram
@PanagiotisCharalampous