Backtesting stop orders (high/low order)
Author: lucadelucia
Creation Date: 11/8/2010 9:28 AM
profile picture

lucadelucia

#1
Hello to the community.
I am trying to write down a code which has two stop orders, one in buy and one in sell.
I am having a problem in backtesting the strategy because i do not know, on the daily chart, whether the high was before the low and vice versa.
Clearly missing this information makes the back testing not reliable.
Does anyone know how to fix this issue?

Thank in advance.

Ciao
L
profile picture

Eugene

#2
profile picture

lucadelucia

#3
Eugene,

thank you very much!
If I do not have intraday data and my orders are all in stop, I can't understand how at stop priority would help?
It is because both the stop orders long and short are the entry orders.
What I am trying to do is simply adding few features to the original code of Pruitt-Hill available on WL4.

Thanks.
L
profile picture

Eugene

#4
QUOTE:
If I do not have intraday data and my orders are all in stop, I can't understand how at stop priority would help?

There's a function for everybody...
QUOTE:
IntradayFillPriorityEstimate

This function, created by Andrew (avishn), helps estimate which limit orders will realistically be hit first - without dropping to the intraday data level.
profile picture

lucadelucia

#5
Eugene,

it is still not all clear but I'll give it a go and see what happens.
I'll keep you updated.
Thanks.

L
profile picture

Eugene

#6
Take a look at the penultimate post at this thread below to have an idea how IntradayFillPriorityEstimate works:

Position Priority - avishn 3/8/2010 9:11 AM
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).