PanagiotisCharalampous's avatar
PanagiotisCharalampous
26 follower(s) 0 following 1006 subscription(s)
Replies

PanagiotisCharalampous
29 Mar 2018, 12:06

Hi irmscher9

Here is a nice article on Reading and Writing CSV Files in C#

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
29 Mar 2018, 11:51

Hi swingfish,

I really appreciate your feedback and I will forward it to the Product Managers of cTrader and cAlgo. We are always open to improvements and that is the reason we are releasing a beta version prior rolling out the platform to brokers.

However I feel the need to defend our choice to merge cTrader and cAlgo. This is not a minor feature, it is an architectural choice and it has been very well thought of. The benefits of it are 

  1. We have only one application and one codebase to manage. This means faster release cycles and full focus of the cAlgo team on the API and the programming part of the platform.
  2. All features are immediately obvious to the trader. So even a novice trader can find out that cTrader has a programming feature as well and feel free to explore it and find our more if she/he wishes to do so.
  3. This change is inline our product wide strategy, this being offering all features in a single trading application. If you have noticed we have also added the Analyze application and soon cMirror will be merged with cTrader as well in the cTrader Copy tab. For the future, we have more applications in mind i.e cTrader Store.

Regarding the disadvantages you mentioned.

  1. There is no restriction in having two instances of cTrader running at the same time. Therefore if you feel uncomfortable trading on a live account and programming a cBot at the same time, just run two instances as you did before. The only difference is that instead of having a cTrader and a cAlgo running, you will have two instances of cTrader. So, I really see no issue here.
  2. Having the two applications merged does not imply that the application will use double the memory. On the other hand, you will save on memory since running only one instance of cTrader will for sure use less memory than two instances. Just for your information there is a UAT in place for cTrader 3.0 not to use more RAM or CPU than cTrader v2.01.

Personally, I see no benefit of having separate applications for manual and automated trading respectively.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
29 Mar 2018, 09:40

Hi Kaworu,

Let's suppose you have a Stochastic Oscillator

private StochasticOscillator _so;

You can a check like the below

_so.PercentK.HasCrossedBelow(_so.PercentD,1);

If you want to check the last value of the D line, then you can use the following property

_so.PercentD.LastValue

Let me know if the above is helpful.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
29 Mar 2018, 09:33

Dear Trader,

Thanks for posting in our forum. Maybe it would be more efficient to contact the authors of these code samples directly. 

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
29 Mar 2018, 09:29

Hi irmscher9,

There is no option to avoid these messages. A workaround would be to save these messages yourself in a csv file. This way you will have no limits in the number of messages you can store.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 15:47 ( Updated at: 21 Dec 2023, 09:20 )

Hi _internet,

You can choose your MA Type from the cBot parameters. See below

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 14:19

Hi irmscher9,

A maximum of 10000 records can be shown in the Log grid. Can you check if you are not exceeding that number?

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 12:40

Hi irmscher,

Which version do you use, 2.01 or 3.0?

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 12:36

Hi FMogyi,

Apologies for the very late reply but this is an old thread, we must have missed it somewhere in the process. Regarding your question, logs are not stored anywhere, only journal information. cAlgo app stores logs in Documents\cAlgo\Journals and cTrader app stores logs in Documents\cTrader\Journals. cAlgo product team has added this feature in the backlog to be considered for a future update.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 12:00

Hi ceakuk,

I would suggest that you always backtest on Tick Data. Backtesting on Tick Data is what would actually happen if you had your cBot running during the backtested period. Backtesting on bars is faster but not so accurate. It is suggested that it is used at the initial stages of developing a cBot and also avoid using it when your cBot depends heavily on logic implemented in the OnTick() method. It could lead to serious deviations in results.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 11:33

Hi Alexander,

cAlgo.API does not provide this information therefore, as you correctly assumed, you need to calculate this information yourself. What you have described sounds as a reasonable approach.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 11:06

Hi Patrick,

Try diff.Hour

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 09:52

Hi andrepasuf,

You can access the last deal using the followng code

History[History.Count - 1]

Let me know if this helps you.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 09:41

Hi tasr1r1,

You can use the Pips property of every position to calculate the AveragePips. This way you will not need to modify your TP on each tick. Symbol.PipSize is not related to this case.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
28 Mar 2018, 09:35

Hi Dave,

Yes it does.

Best Regards

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
27 Mar 2018, 15:15

Hi,

You can have public properties of type double in an indicator and read them from a cBot. They don't need to be output properties. See below

public int LastValue;

Then you can read these properties from cBots like below

         protected override void OnStart()
        {
            _renko = Indicators.GetIndicator<Renko>();
        }
        protected override void OnBar()
        {      
           var renko = _renko.LastValue;
        }

Let me know if this helps.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
27 Mar 2018, 14:43

Hi ceakuk,

It is currently not possible to draw objects during backtesting. This will be added in a future release.

Regarding the output issue, could you please share the cBot and the Indicator so that we can advise you what is wrong with the code?

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
27 Mar 2018, 14:41

Hi, 

It is possible to return double values using an indicator. If you provide us with your indicator, we might be able to show you how to do this.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
27 Mar 2018, 14:34

Dear Trader,

Thanks for posting in our forum. What you need to do is to divide the difference by Symbol.PipSize. See below

var differenceInPips = Math.Abs((Price1 - Price2) / Symbol.PipSize);

Let me know if this helps you.

Best Regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
27 Mar 2018, 14:16

Dear Trader,

Thanks for posting in our forum. Such property is not available since it doesn't make sense in the context of a robot. A robot is always executed on the last bar in contrast to an indicator that needs to calculate the values of all previous bars before calculating the last one. If you can become more specific to what you are trying to do then maybe we could direct you towards the correct solution.

Best Regards,

Panagiotis


@PanagiotisCharalampous