Retro look back last bar and exit on stop condition

Questions about MultiCharts and user contributed studies.
martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Retro look back last bar and exit on stop condition

Postby martingale » 07 May 2012

I'm trying to implement a back test signal that can look back at last bar, say it's on 5 minute bar, and if last bar's high or low break my stop loss condition, i want MC make an exit trade that exit on the stop loss price in that bar.
is there a way to do this?

my idea for above is, run a if loop at begin of each bar for non stop condition, else exit at stop if hit.
e.g.

begin
if condition A then
// do something
else
sell next bar at stop_loss_price stop ;

but it doesn't seem to work well.

any help?

thanks

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 08 May 2012

martingale wrote:I'm trying to implement a back test signal that can look back at last bar, say it's on 5 minute bar, and if last bar's high or low break my stop loss condition, i want MC make an exit trade that exit on the stop loss price in that bar.
is there a way to do this?

my idea for above is, run a if loop at begin of each bar for non stop condition, else exit at stop if hit.
e.g.

begin
if condition A then
// do something
else
sell next bar at stop_loss_price stop ;

but it doesn't seem to work well.

any help?

thanks

Please be more precise in your description.
Provide a sample code you are using and explain what exactly does not work as you expected.
Please also let us know what chart resolution you are using and what is IOG status (turned on or off).

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 08 May 2012

Henry Multicharts wrote:
martingale wrote:I'm trying to implement a back test signal that can look back at last bar, say it's on 5 minute bar, and if last bar's high or low break my stop loss condition, i want MC make an exit trade that exit on the stop loss price in that bar.
is there a way to do this?

my idea for above is, run a if loop at begin of each bar for non stop condition, else exit at stop if hit.
e.g.

begin
if condition A then
// do something
else
sell next bar at stop_loss_price stop ;

but it doesn't seem to work well.

any help?

thanks

Please be more precise in your description.
Provide a sample code you are using and explain what exactly does not work as you expected.
Please also let us know what chart resolution you are using and what is IOG status (turned on or off).



thanks Henry

e.g. I'm using 3 min bar, no tick data.
let's say I enter a long position at 1400 at time 10:00, set a stop loss at 1395.
if at 10:12 bar, market close at 1396, but low of that bar is at 1394.5, which means at some time in that bar, my stop order is triggered, so I want my backtest code to exit with a stop order of 1395 in 10:12 bar.

I don't have a working code to realize that function. do you know how to do this?

btw, what is IOG, how to use it?

thanks

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 09 May 2012

I'm trying to use 1 min bar and create a counter to calculate at every end of 3 min cycle, but definitely won't reach my purpose..

so is there a way to go back to the begin of the bar and force portfolio backtester to enter a stop trade at ( avgEntryPrice +/- stoploss ) level at the close of a bar?

thanks

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 10 May 2012

So you are using a 3 minute bar. You have placed a stop order at 1395 and this price is met inside the bar->stop order should be executed. MultiCharts is using intra-bar price movement assumptions to infer the actual price movement within each bar.
Once you set a stop order - it will be active and awaiting execution price or worse.
It will be resent if the condition is met on the next bar and cancelled if the condition is no longer met.

Next bar orders are sent to the broker upon next tick after the signal generation tick. That is possible to send Market and Price Next bar orders.
IOG On (tick by tick calculation)-order is generated on the current tick and sent on the next tick.
IOG Off (calculation on the close of the bar)-order is generated on the close of the current bar and sent on the opening tick of the next bar.

martingale wrote:so is there a way to go back to the begin of the bar and force portfolio backtester to enter a stop trade at ( avgEntryPrice +/- stoploss ) level at the close of a bar?


This Bar on Close order is sent on the close of the signal generation bar. Only market orders can be sent This bar. Buy Next bar at open = Buy Next bar at Market;

You can refer to the current bar OHLC values. Open of this bar:

Code: Select all

open

You can refer to the previous bar OHLC values. Close 1 bar ago:

Code: Select all

close[1]


You can find useful information about coding on the Power Language at this web page under Additional information sources:
https://www.multicharts.com/trading-soft ... on_Sources
Complete list of PowerLanguage Keywords can be found at this page under PowerLanguage Keyword Reference section:
https://www.multicharts.com/trading-soft ... /Main_Page

You can also find "Getting started with EasyLanguage" book over the Internet.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 10 May 2012

Henry Multicharts wrote:So you are using a 3 minute bar. You have placed a stop order at 1395 and this price is met inside the bar->stop order should be executed. MultiCharts is using intra-bar price movement assumptions to infer the actual price movement within each bar.
Once you set a stop order - it will be active and awaiting execution price or worse.
It will be resent if the condition is met on the next bar and cancelled if the condition is no longer met.

Next bar orders are sent to the broker upon next tick after the signal generation tick. That is possible to send Market and Price Next bar orders.
IOG On (tick by tick calculation)-order is generated on the current tick and sent on the next tick.
IOG Off (calculation on the close of the bar)-order is generated on the close of the current bar and sent on the opening tick of the next bar.

martingale wrote:so is there a way to go back to the begin of the bar and force portfolio backtester to enter a stop trade at ( avgEntryPrice +/- stoploss ) level at the close of a bar?


This Bar on Close order is sent on the close of the signal generation bar. Only market orders can be sent This bar. Buy Next bar at open = Buy Next bar at Market;

You can refer to the current bar OHLC values. Open of this bar:

Code: Select all

open

You can refer to the previous bar OHLC values. Close 1 bar ago:

Code: Select all

close[1]


You can find useful information about coding on the Power Language at this web page under Additional information sources:
https://www.multicharts.com/trading-soft ... on_Sources
Complete list of PowerLanguage Keywords can be found at this page under PowerLanguage Keyword Reference section:
https://www.multicharts.com/trading-soft ... /Main_Page

You can also find "Getting started with EasyLanguage" book over the Internet.


thanks Henry

in the link you provided for intra-bar price movement,
https://www.multicharts.com/trading-soft ... ssumptions

let's say i put a stop loss sell order at 1345. the price hit low at 1340, it means somewhere in the bar my stop order is triggered, in this case, how can i code it such that the actual trade in my backtest signal will put a sell trade at 1345 rather than the low of 1340.

thanks

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 14 May 2012

martingale wrote:let's say i put a stop loss sell order at 1345. the price hit low at 1340, it means somewhere in the bar my stop order is triggered, in this case, how can i code it such that the actual trade in my backtest signal will put a sell trade at 1345 rather than the low of 1340.
thanks

A Stop order will execute at the specified price or worse. A worse price is a higher price for Buy and Buy to cover orders, and a lower price for Sell and Sell short orders.

For sell stop @ 1345: if the order is generated and on the next bar the opening price is 1340 – it satisfies the condition and the order is placed on this price level. If open of the next bar is above 1345 but low of the bar still meets the condition- then the order will be placed at 1345.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 14 May 2012

Henry Multicharts wrote:
martingale wrote:let's say i put a stop loss sell order at 1345. the price hit low at 1340, it means somewhere in the bar my stop order is triggered, in this case, how can i code it such that the actual trade in my backtest signal will put a sell trade at 1345 rather than the low of 1340.
thanks

A Stop order will execute at the specified price or worse. A worse price is a higher price for Buy and Buy to cover orders, and a lower price for Sell and Sell short orders.

For sell stop @ 1345: if the order is generated and on the next bar the opening price is 1340 – it satisfies the condition and the order is placed on this price level. If open of the next bar is above 1345 but low of the bar still meets the condition- then the order will be placed at 1345.


thanks Henry and I understand that part. so what kind of code to simulate the 2nd scenario as you mentioned in PL.

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 14 May 2012

martingale wrote:
Henry Multicharts wrote:
martingale wrote:let's say i put a stop loss sell order at 1345. the price hit low at 1340, it means somewhere in the bar my stop order is triggered, in this case, how can i code it such that the actual trade in my backtest signal will put a sell trade at 1345 rather than the low of 1340.
thanks

A Stop order will execute at the specified price or worse. A worse price is a higher price for Buy and Buy to cover orders, and a lower price for Sell and Sell short orders.

For sell stop @ 1345: if the order is generated and on the next bar the opening price is 1340 – it satisfies the condition and the order is placed on this price level. If open of the next bar is above 1345 but low of the bar still meets the condition- then the order will be placed at 1345.


thanks Henry and I understand that part. so what kind of code to simulate the 2nd scenario as you mentioned in PL.

I believe it is the same code as you are already using

Code: Select all

sell next bar at 1345 stop

The thing is not in the code but in the bar the order is placed on.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 14 May 2012

Henry Multicharts wrote:I believe it is the same code as you are already using

Code: Select all

sell next bar at 1345 stop

The thing is not in the code but in the bar the order is placed on.


So Henry you mean the code will auto look for lowest value that triggered 1345 sell condition. and if triggered will sell at the next bar at price 1345?

i did the same code, but it didn't sell at that price. is there something or some setting I need to take care in properties?

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 15 May 2012

The code will check wether condition is met or not, if the condition is met - it will place an order next bar. A Stop order will execute at the specified price or worse. A worse price is a higher price for Buy and Buy to cover orders, and a lower price for Sell and Sell short orders.

If you consider that the order is filled at the incorrect price please send the piece of code you are using and screenshots demonstrating the OHLC of the previous bar and OHLC of order execution bar or come to our live chat Monday-Friday 6:30 am - 4 pm EST. We will do our best to help you..

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 16 May 2012

Henry Multicharts wrote:The code will check wether condition is met or not, if the condition is met - it will place an order next bar. A Stop order will execute at the specified price or worse. A worse price is a higher price for Buy and Buy to cover orders, and a lower price for Sell and Sell short orders.

If you consider that the order is filled at the incorrect price please send the piece of code you are using and screenshots demonstrating the OHLC of the previous bar and OHLC of order execution bar or come to our live chat Monday-Friday 6:30 am - 4 pm EST. We will do our best to help you..



here is my code and bt trade.

if mycondition = true
sellshort("short")this bar at close;
end;

if MarketPosition(0) = -1 then
buytocover next bar at ( avgentryprice + maxlossIntraBar ) stop;

//if stop loss not met
//doing something else.
end;

I'm using 3 min bar, my resolution is 1min data.
trade analysis : at the bar ending at 9:57, enter short at 1561.0
OHLC for 9:57 - 10:00 bar is 1561.0, 1573.5, 1560.5, 1572.5
the exit trade take place buy long 1 contract at 1572.5 which is the open at 10:03.

do you think anyhing is wrong with my code ?

thanks

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 17 May 2012

What exactly is incorrect in your opinion?
If in backtesting the order has been generated with price 1572.5 and filled with this price at the open of the next bar then I do not see anything incorrect.
Please be more precise in your description and attach screenshots demonstrating your charts and OHLC of the bars or come to our live chat Monday-Friday 6:30 am - 4 pm EST.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 17 May 2012

Henry Multicharts wrote:What exactly is incorrect in your opinion?
If in backtesting the order has been generated with price 1572.5 and filled with this price at the open of the next bar then I do not see anything incorrect.
Please be more precise in your description and attach screenshots demonstrating your charts and OHLC of the bars or come to our live chat Monday-Friday 6:30 am - 4 pm EST.


my mistake Henry.
I forgot to mention that my stop loss is 5 handle. so i enter short at 1561, it should buyToCover at 1566. since the high of the bar is 1573.5, it should triggered the stoploss condition somewhere in the bar; but it some how exit next bar at a price of 1572.5 which is too much loss.

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 18 May 2012

Here is my understanding of your situation. Please correct me if I am wrong.

At the bar ending at 9:57, enter short at 1561.0 (MP becomes -1).
Next bar ending at 10:00 MP is -1, then buytocover next bar -> generates a stop order at 1566 that will be sent on the next bar.

Buytocover will execute at the specified price or worse (a worse price is a higher price in this example). So @1566 or higher.

The exit trade takes place buy long 1 contract at 1572.5 which is the open at 10:03.
1572.5 is the opening price of the bar that satisfies the order parameters you have specified->the order is filled at once.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 18 May 2012

Henry Multicharts wrote:Here is my understanding of your situation. Please correct me if I am wrong.

At the bar ending at 9:57, enter short at 1561.0 (MP becomes -1).
Next bar ending at 10:00 MP is -1, then buytocover next bar -> generates a stop order at 1566 that will be sent on the next bar.

Buytocover will execute at the specified price or worse (a worse price is a higher price in this example). So @1566 or higher.

The exit trade takes place buy long 1 contract at 1572.5 which is the open at 10:03.
1572.5 is the opening price of the bar that satisfies the order parameters you have specified->the order is filled at once.


no. i'm trying to buy to cover at 1566 within the bar ending at 10:00 since the high of that bar exceed 1566.

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 21 May 2012

martingale wrote:no. i'm trying to buy to cover at 1566 within the bar ending at 10:00 since the high of that bar exceed 1566.

You are sending buy to cover order next bar, not the same 10:00 bar.

Code: Select all

if MarketPosition(0) = -1 then
buytocover [b]next bar[/b] at ( avgentryprice + maxlossIntraBar ) stop;

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 22 May 2012

Henry Multicharts wrote:
martingale wrote:no. i'm trying to buy to cover at 1566 within the bar ending at 10:00 since the high of that bar exceed 1566.

You are sending buy to cover order next bar, not the same 10:00 bar.

Code: Select all

if MarketPosition(0) = -1 then
buytocover [b]next bar[/b] at ( avgentryprice + maxlossIntraBar ) stop;


that's what i see, so my question is is there a way to execute at exactly the stop loss price, in a way to simulate real time trading.

does that require a tick level data?

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 23 May 2012

Henry Multicharts wrote:So you are using a 3 minute bar. You have placed a stop order at 1395 and this price is met inside the bar->stop order should be executed. MultiCharts is using intra-bar price movement assumptions to infer the actual price movement within each bar.


This Bar on Close order is sent on the close of the signal generation bar. Only market orders can be sent This bar. Buy Next bar at open = Buy Next bar at Market;

You can refer to the current bar OHLC values. Open of this bar:

Code: Select all

open

You can also find "Getting started with EasyLanguage" book over the Internet.


Hi Henry, if i set intrabarordergeneration = true in my 3 min bar which is consist of 1 min data, does that mean i'm actually only using 1 min bar for all calculation?

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 25 May 2012

martingale wrote:
Henry Multicharts wrote:
martingale wrote:no. i'm trying to buy to cover at 1566 within the bar ending at 10:00 since the high of that bar exceed 1566.

You are sending buy to cover order next bar, not the same 10:00 bar.

Code: Select all

if MarketPosition(0) = -1 then
buytocover [b]next bar[/b] at ( avgentryprice + maxlossIntraBar ) stop;

that's what i see, so my question is is there a way to execute at exactly the stop loss price, in a way to simulate real time trading.
does that require a tick level data?

There is no command to execute at stop price exactly. That is against the nature of stop order.
But your buy stop order can be filled in backtesting if the order stop price is above opening price of the bar.
Attachments
buy stop.png
buy stop.png (24.34 KiB) Viewed 780 times

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 25 May 2012

martingale wrote:
Henry Multicharts wrote:So you are using a 3 minute bar. You have placed a stop order at 1395 and this price is met inside the bar->stop order should be executed. MultiCharts is using intra-bar price movement assumptions to infer the actual price movement within each bar.


This Bar on Close order is sent on the close of the signal generation bar. Only market orders can be sent This bar. Buy Next bar at open = Buy Next bar at Market;

You can refer to the current bar OHLC values. Open of this bar:

Code: Select all

open

You can also find "Getting started with EasyLanguage" book over the Internet.


Hi Henry, if i set intrabarordergeneration = true in my 3 min bar which is consist of 1 min data, does that mean i'm actually only using 1 min bar for all calculation?

No, with IOG enabled on historical data-the script is calculated four times on OHLC (of 3 min bar). MultiCharts considers that there were only OHLC values->order is filled only on OHLC prices.
Last edited by Henry MultiСharts on 29 May 2012, edited 1 time in total.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 28 May 2012

Hi Henry

I enabled [IntrabarOrderGeneration = true]; but back test still shows exit at close of 3 min bar even i put in tick data.

i noticed my IntrabarOrderGeneration = true is actually faded, can that be the cause of not using tick data for calculation of exit? i attached a snapshot for you.
Attachments
IOG_faded.jpg
IOG_faded.jpg (3.75 KiB) Viewed 766 times

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 29 May 2012

martingale wrote:Hi Henry
I enabled [IntrabarOrderGeneration = true]; but back test still shows exit at close of 3 min bar even i put in tick data.
i noticed my IntrabarOrderGeneration = true is actually faded, can that be the cause of not using tick data for calculation of exit? i attached a snapshot for you.


Hello Martingale,

I have edited my previous post with the correct information.

Enabling IOG does not make your strategy to be calculated on the tick data in backtesting. Enabling IOG makes the script to be calculated four times on OHLC (of main data series bar).
If you want your strategy to be calculated on 1 tick data you need to enable Bar Magnifier.

Here is how the calculation will be performed for MC 8.0 beta 3 and higher:

Scenario A: Calculation on historical data. Regular mode. No IOG. No Bar Magnifier.
The script is calculated on the bar close. It is considered that all prices were within the bar (Price movement assumption is used). Order filled on any price within the bar.

Scenario B: Calculation on historical data. IOG enabled. No Bar Magnifier.
The script is calculated four times on OHLC. MultiCharts considers that there were only OHLC values->order is filled only on OHLC prices.

Scenario C: Calculation on historical data. IOG and Bar Magnifier enabled.
The script is calculated on the Open value of the main data series, then OHLC of each bar of the detailed data series selected in bar magnifier (Price movement assumption is used), then on the Close of the main data series. Order is filled only on these O-OHLC-C values.

Scenario D: Calculation on historical data. No IOG. Bar Magnifier enabled.
The script is calculated 1 time on main data series close. MultiCharts considers that there were only OHLC values of the detailed data series->order is filled only on OHLC prices.


Please provide more details on "IntrabarOrderGeneration = true is faded". What version and build number of MultiCharts are you running (MultiCharts->help tab->About MultiCharts)?
Can the signal be compiled successfully with [IntrabarOrderGeneration = true] line?
Last edited by Henry MultiСharts on 30 May 2012, edited 1 time in total.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 29 May 2012

Henry Multicharts wrote:
martingale wrote:Hi Henry
I enabled [IntrabarOrderGeneration = true]; but back test still shows exit at close of 3 min bar even i put in tick data.
i noticed my IntrabarOrderGeneration = true is actually faded, can that be the cause of not using tick data for calculation of exit? i attached a snapshot for you.


Hello Martingale,

I have edited my previous post with the correct information.

Enabling IOG does not make your strategy to be calculated on the tick data in backtesting. Enabling IOG makes the script to be calculated four times on OHLC (of main data series bar).
If you want your strategy to be calculated on 1 tick data you need to enable Bar Magnifier.

Here is how the calculation will be performed for MC 8.0 beta 3 and higher:

Scenario A: Calculation on historical data. Regular mode. No IOG. No Bar Magnifier.
The script is calculated on the bar close. It is considered that all prices were within the bar (Price movement assumption is used). Order filled on any price within the bar.

Scenario B: Calculation on historical data. IOG enabled. No Bar Magnifier.
The script is calculated four times on OHLC. MultiCharts considers that there were only OHLC values->order is filled only on OHLC prices.

Scenario C: Calculation on historical data. IOG and Bar Magnifier enabled.
The script is calculated on the Open value of the main data series, then OHLC of each bar of the detailed data series selected in bar magnifier (Price movement assumption is used), then on the Close of the main data series. Order is filled only on these O-OHLC-C values.

Scenario D: Calculation on historical data. No IOG. Without Bar Magnifier enabled.
The script is calculated 1 time on main data series close. MultiCharts considers that there were only OHLC values of the detailed data series->order is filled only on OHLC prices.


Please provide more details on "IntrabarOrderGeneration = true is faded". What version and build number of MultiCharts are you running (MultiCharts->help tab->About MultiCharts)?
Can the signal be compiled successfully with [IntrabarOrderGeneration = true] line?


thanks Henry. this gave me a better picture.

1. i'm using v7.4. would you give me a link where to download beta 8.3? i only see 8.0 beta here
https://www.multicharts.com/trading-software-download/

2. i enabled 'bar magnifier' in MC chart window, and run my backtest in portfolio backtester on tick data, seems stop loss order still not exit at right price.
is it possible due to my ver7.4 ?

3. what's the difference between your scenario A and D, both no IOG or magnifier.

thanks.

martingale
Posts: 79
Joined: 10 Dec 2010
Has thanked: 2 times
Been thanked: 1 time

Re: Retro look back last bar and exit on stop condition

Postby martingale » 29 May 2012

Henry Multicharts wrote:
martingale wrote:Hi Henry
Can the signal be compiled successfully with [IntrabarOrderGeneration = true] line?


Henry
I tried put SetStopLoss(10); it seems work. want you to help me confirm this.
confused.

User avatar
Henry MultiСharts
Posts: 8443
Joined: 25 Aug 2011
Has thanked: 1207 times
Been thanked: 2703 times

Re: Retro look back last bar and exit on stop condition

Postby Henry MultiСharts » 30 May 2012

martingale wrote:thanks Henry. this gave me a better picture.
1. i'm using v7.4. would you give me a link where to download beta 8.3? i only see 8.0 beta here
https://www.multicharts.com/trading-software-download/
2. i enabled 'bar magnifier' in MC chart window, and run my backtest in portfolio backtester on tick data, seems stop loss order still not exit at right price.
is it possible due to my ver7.4 ?
3. what's the difference between your scenario A and D, both no IOG or magnifier.
thanks.


1) Release candidate version is already available. You can download it from this page:
https://www.multicharts.com/trading-software-download/

2) This information is not sufficient. Please come to our live chat if you have any specific question regarding order placement in backtesting.

3) Sorry for this typo. I have modified the previous post.


Return to “MultiCharts”