Programming breakout strategy question  [SOLVED]

Questions about MultiCharts and user contributed studies.
User avatar
Xurma
Posts: 31
Joined: 24 Nov 2020
Has thanked: 9 times

Programming breakout strategy question

Postby Xurma » 21 Dec 2020

Hello.
I have breakout strategy. When condition is ready it will send sellshort and buy orders. The code is below. How to make only 1 trade in the bar when outside bars happens? My opinion is to going on lower time frame and manage trade from there. But maybe you can help me with more correct decision for than.

Code: Select all

if cond then begin buy("LE") next bar high stop; sellshort("SE") next bar low stop; Setstoploss(stopv); end;
Image
Attachments
MS_breakout.jpg
(50.13 KiB) Not downloaded yet

User avatar
TJ
Posts: 7742
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: Programming breakout strategy question

Postby TJ » 22 Dec 2020

There is an option to make only ONE trade per bar.

User avatar
Xurma
Posts: 31
Joined: 24 Nov 2020
Has thanked: 9 times

Re: Programming breakout strategy question  [SOLVED]

Postby Xurma » 22 Dec 2020

There is an option to make only ONE trade per bar.
I made it, but getting worse. Now it trades every bar. I tryed different combination of this menu and every combination was like this on picture.
Attachments
once.jpg
(317.44 KiB) Not downloaded yet


Return to “MultiCharts”