Topic: custom code

Hi guys, it's been awhile, nice to be back!  Wife didn't like me trading but now we're divorced lol.

I seem to remember it being very easy to program indicators and custom codes for stats, but now I can't seem to do anything.  Also creating the mqh files was fairly easy before.  Is my memory bad, or has something changed?

I don't really see any logic in the current .cs files, and I think I am missing include files?

Any help would be appreciated, thanks!

Re: custom code

Hey, Jet! Nothing has changed, everything is as before. The devil is in the details and usually when new indi makers appear and say easy-peasy, then after that their work need a lot of fixing in regard to the main concept of the program smile

Tell us what you need to know in detail and we can go on from there (mind you, I'm mostly self-taught, so this hinders my teaching ability somewhat, I'm at my best in details).

Re: custom code

Hey Footon! Happy to see you're still around! I figured you made your millions and are off living on some island full of beautiful girls haha smile

OMG, I must be going senile in my old age.  I taught myself before but now I'm totally lost. Maybe if you could point me in the right direction it will all come back to me.

What I'm trying to do is sort of like a take profit trailing stop.  But instead of following the price up, it goes down toward the price until the price hits it and sells.

Maybe i'm not explaining it well.  But I've noticed during backtesting many times I've seen +50 or +100 only to see it all disappear because the price didn't hit the TP.   I'm thinking either to lower the TP as the price goes up, Or just keep lowering it by a certain amount over time.

What I tried doing was combining the Take profit indicator and the trailing stop indicator and merge them.

it was doing something but I'm not exactly sure what.  I would show it to you but I deleted it out of frustration lol.

Is there a way in FSB to view indicators in real time during a backtest, like how Metatrader does it? There must be some way we can see what the indicator is actually doing right?

Well, time for me to hit the hay.  I actually moved to Bangkok and have been living here over a year now with my thai girlfriend.  I really like it here.  We're like 6 hours ahead of London time.  ttyl and take care!

Jet

Re: custom code

Welcome back Jetaro!

> What I tried doing was combining the Take profit indicator and the trailing stop indicator and merge them.

We already did that 10 years ago smile

Please see the "Trailing Stop Limit" indicator under the "Closing Point  of the Position" slot.

Re: custom code

jetaro wrote:

Hey Footon! Happy to see you're still around! I figured you made your millions and are off living on some island full of beautiful girls haha smile

OMG, I must be going senile in my old age.  I taught myself before but now I'm totally lost. Maybe if you could point me in the right direction it will all come back to me.

What I'm trying to do is sort of like a take profit trailing stop.  But instead of following the price up, it goes down toward the price until the price hits it and sells.

Maybe i'm not explaining it well.  But I've noticed during backtesting many times I've seen +50 or +100 only to see it all disappear because the price didn't hit the TP.   I'm thinking either to lower the TP as the price goes up, Or just keep lowering it by a certain amount over time.

What I tried doing was combining the Take profit indicator and the trailing stop indicator and merge them.

it was doing something but I'm not exactly sure what.  I would show it to you but I deleted it out of frustration lol.

Is there a way in FSB to view indicators in real time during a backtest, like how Metatrader does it? There must be some way we can see what the indicator is actually doing right?

Well, time for me to hit the hay.  I actually moved to Bangkok and have been living here over a year now with my thai girlfriend.  I really like it here.  We're like 6 hours ahead of London time.  ttyl and take care!

Jet

In addition what is said above, the TP indi cannot be customized, there's no way to for the custom indicator to see position info. So modifying TP is practically almost un-doable, theoretically maybe some tricks will work but it would be such a huge experimentation with a reliability risk. Better to modify the EA itself?

Isn't the indicator chart enough to see what it is doing? Essentially the backtest is instantaneous and what you see on chart gets used in the backtest. You can add additional indicator components to see more values if it is necessary (trace array values or something similar).

Bangkok sounds too hot smile

Good night!

Re: custom code

Popov wrote:

Welcome back Jetaro!

> What I tried doing was combining the Take profit indicator and the trailing stop indicator and merge them.

We already did that 10 years ago smile

Please see the "Trailing Stop Limit" indicator under the "Closing Point  of the Position" slot.


oh really?  cool! I will check that out right away.
nice to see you all here! it's been like 5 years!
I hope all is well!