Worried that Market-makers will come and ‘hunt’ your StopLoss orders?

You are probably just being paranoid - unless you have chosen a broker that is not a genuine ECN (i.e. a Market maker or non-ECN broker that operates their own dealing desks).
It is however a common fear based on the distinction between smart money (namely, institutional traders) and less sophisticated retail traders (namely, you & me). Experience tells us that the big boys will look to buy when retail traders are selling, and mop up your StopLoss orders. Eventually, volume will drive a price reversal, the pendulum will swing back, larger traders will begin to sell, and smaller traders begin buying - and so the cyclic waves of price action continue.

If you are concerned about telling the world where your StopLoss or TakeProfit levels are (by having pending LIMIT or STOP orders open) a good tactic that can help you sleep better, is to simply not place any StopLoss orders !!
Instead you can implement onTick code to close your Position when it meets a Loss limit (or Profit target).
Compare history.getEquity() to the Equity saved from when you opened the order - the maths is then simple to then work out if the %age loss (or gain) exceeds your SL pips (or TP pips) and close the order.

Note if your Strategy creates positions with a variety of StopLoss levels depending on buy/sell signals used, then the SL can be stored in the Order comment & retrieved onTick via order.getComment() (and convert the String back to an integer or double).

You will of course need to run your Strategy on Dukascopy remote servers, so you are insulated from local failures / network disruptions.
Translate to English Show original