Iceberg Order Slicer
A single large market order announces itself: it is one line on the time and sales tape, at one size, at one moment. This EA takes a target position and builds it out of a stream of much smaller child orders, each drawn from a size range and separated by a randomised gap, so the pattern does not read as one deliberate build-up. Both randomisations matter together. A fixed slice size at a fixed cadence is trivially pattern-matched by anyone actually watching the tape, which defeats the purpose entirely - random size alone, or random timing alone, each still leaves the other half of the pattern intact. Progress toward the target is measured by summing this EA's own currently open lots on the chart symbol and magic number, not by counting how many slices were sent - a slice that gets rejected or requoted is therefore corrected for automatically on a later pass instead of silently leaving the position under target. This EA only builds the position. It does not attach a stop loss or take profit to the slices it sends, and it does not manage the resulting position once built - that is a separate concern, left to whatever risk management tool you normally run alongside it. Notes and limitations - Building the target across many small orders still carries the same total market exposure as one large order once it is complete - slicing hides the footprint of the entry, it does not reduce the risk of the finished position. - Each slice pays its own spread and, on a commission account, its own commission - more slices means more total execution cost, so there is a real trade-off against a smaller number of larger clips. - No stop loss or take profit is attached to any slice. Pair this with a separate risk-management EA if the built position needs protecting. - If the terminal or EA stops running mid-build, whatever has already filled remains open and unmanaged; the remainder of the target is simply never sent.
Expert advisor · MT4 · v1.0 · Free
About Iceberg Order Slicer
Iceberg Order Slicer is an expert advisor (trading robot) for MetaTrader 4. It has 11 settings, such as Direction, Target lots and Min slice lots. MQL source code included.
Files in the download: IcebergOrderSlicer.ex4, IcebergOrderSlicer.mq4, IcebergOrderSlicer.txt.
Trading robots can lose money. Check every setting and test on a demo account before using real funds.
Settings
| Setting | Default | What it does |
|---|---|---|
| Direction | ICEBERG_BUY | Direction to build |
| Target lots | 1.00 | Total position size to build |
| Min slice lots | 0.10 | Smallest child order size |
| Max slice lots | 0.30 | Largest child order size |
| Min interval seconds | 20 | Shortest gap between child orders |
| Max interval seconds | 90 | Longest gap between child orders |
| Start trading | false | Must be true for the EA to actually send orders |
| Magic number | 20261201 | Magic number identifying this build |
| Slippage pips | 3 | Slippage tolerance, in pips |
| Max retries | 5 | Attempts per slice before giving up on it |
| Retry wait ms | 500 | Pause between attempts, milliseconds |
How to install
- Download the ZIP from your PolyMaria library and unzip it.
- In MetaTrader 4 open File → Open Data Folder, then go to MQL4 → Experts.
- Copy the .mq4 file(s) there. Put any .mqh files in MQL4 → Include.
- Open the .mq4 file in MetaEditor and press Compile (F7) if MetaTrader does not show it.
- Drag the expert advisor from the Navigator onto a chart, check the settings, allow Algo/Auto Trading and press OK.
- Test it first on a demo account or in the Strategy Tester.
Tags: MT4 Expert Advisor · MQL4 Source Code