Ralf,
I am a complete TS illiterate, thus I don't understand your snippet
if marketposition<>1 then buy at highest(high,2)+trigger stop;
if marketposition<>-1 then sell at highest(high,2)-trigger stop;
but it leaves me wondering if you are testing p&f. Although p&f is most useful in detecting breakouts, it goes beyond this. A frequently used term in p&f is that it shows "the battle between supply and demand" which is why p&f-trading is mostly based on some patterns that exhibit this struggle of interests. I doubt a single line of TS code could catch this.
Another thing I have noticed is that there are very few software packages that compute p&f charts as intended. In fact, I am only aware of Bull's Eye Broker and PNFscan who do so correctly. Both won't help you, as they are (to my knowledge) both just EOD.
The two masters of p&f application, Chartcraft and Dorsey, will leave you helpless as well, because their work is (afaik) also only EOD, plus they add sector centric and sentiment views to their work.
I doubt any of the commercially available software packages will give you the options at hand to really test p&f without major coding work. These packages are, to my knowledge, all based on bars or ticks, and this is what you have access to in their respective programming language.
In p&f, a bar or tick is somewhat converted into columns of X and O - if a bar/tick doesn't lead to a new X or O it gets lost, it's considered "noise". So a truly p&f enabled software leaves you with the X and O information (most recent and past) and fire trigger events as new patterns evolve. For your testing, you would need to capture these events, which, in the simplest case, is a breakout. Which leaves "only" the definition open as to what a breakout is.
What probably comes more intuitive are Renko charts, as they don't drop the time information, leaving the bar/tick concept somewhat intact, still using the idea of "noise reduction" as in p&f.
My personal opinion on "standard" p&f charting is that it doesn't work anymore. Although, using proper money management, you could make some money using standard patterns, it won't make you rich. At least this is what my backtesting shows. Chartcraft and Dorsey add some twists in terms of risk management, but again this is not the holy grail.
Best thing to do is probably to ask some of the many TS user groups and the Software forum on ET for some TS guru's to help you out with a p&f-starter-kit, then follow your own route. I promise p&f can be profitable, but it definitely is not, when used as a black-box system.
I now may have created more new questions than answered. But what the hell
A+,
Andreas