Lot Size From Risk And Stop
- Утилиты
-
Ralph Ivan Simeon
I build and audit automated trading systems for MetaTrader 5, with most of my work on XAUUSD. - Версия: 1.0
Most lot size calculators assume one pip is worth ten dollars. That assumption is wrong on gold, wrong on indices, wrong on JPY crosses, and wrong on every account not denominated in USD - which is to say, wrong exactly where oversizing hurts.
This one asks your server instead. It reads the tick value, tick size, point size, volume step and margin requirements actually published for the symbol on your chart, so the number it gives you is the number your account will accept.
How it works
Attach it to a chart. A dashed line appears at your stop level - drag it wherever your stop belongs and the panel recalculates instantly. Type the risk as a percentage of your account or as a cash amount, and switch between LONG and SHORT with one click.
The panel shows you:
- the lot size, large and unambiguous
- what you are actually risking in account currency
- the stop distance in points, and in pips on 3- and 5-digit symbols
- what one point is worth per 1.00 lot on this instrument
- the margin the position needs, and your free margin after opening it
What it will not do
It never places, modifies or closes an order. It reads your account and the symbol; it does not trade. Attach it with confidence to a live chart.
Three deliberate behaviours
It always rounds the lot size DOWN onto the volume step. Rounding up would silently risk more than you asked for, and a risk tool that does that is worse than no tool. You will see the rounded figure and what it really risks.
When your intended risk is smaller than the minimum lot, it does not quietly hand you the minimum and stay silent. It shows the minimum in red and tells you what that position actually risks, which will be more than you wanted.
When your stop is on the wrong side of the entry for the direction you have selected, it says so, rather than using the absolute distance and pretending everything is fine.
Requirements
MetaTrader 5, any symbol in Market Watch. No DLLs, no external dependencies, no internet access, and no settings to tune before it works.
