Broker API HubMenu

EarnForex/PositionSizer

Dark candlestick chart of EUR/USD with a light panel titled Position Sizer on top. The panel has fields for entry, stop-loss, take-profit, ATR settings, commission, account balance, risk and reward, and a resulting position size of 0.05. Lines on the chart mark the stop-loss and take-profit levels.
The Position Sizer panel on a EUR/USD daily chart, working out a position size from an entry, a stop-loss, a risk percentage and an account balance. Image from the repository's README. Copyright the EarnForex/PositionSizer authors. Licence: Apache-2.0. Source file on GitHub, copied and resized. How images are chosen.

In its own words: Calculate your position size based on the risk and account size and execute your trades with this free MetaTrader expert advisor.

Independent and unofficialRead from GitHub

Open EarnForex/PositionSizer on GitHub

Risk warning: CFDs and spread bets are complex instruments and come with a high risk of losing money rapidly due to leverage. You can lose money on these products, and each provider publishes its own loss figure under FCA rules. You should consider whether you understand how they work and whether you can afford to take the high risk of losing your money. Automated and API trading can amplify losses through bugs, connectivity failures and runaway orders.

The facts

Stars
596
Forks
221
Language
MQL5
Licence
Apache-2.0
Created
Last push
Kind
Broker and platform API client
Read from GitHub
github.com/EarnForex/PositionSizerchecked

Stars measure attention, not quality or safety. Nothing here reviews the code or its author. Read the licence, the open issues and the code itself before you run anything against an account. Star velocity: unmeasurable, because this site holds one reading for this repository.

Get started in a couple of minutes

You need Git installed. Then, in a terminal:

git clone https://github.com/EarnForex/PositionSizer.git
cd PositionSizer

From there, follow the README for how to build and run it.

These are the usual steps for a project in this language, not instructions taken from this repository. Its README has the exact commands, and it wins wherever the two differ.

Before you connect anything to a broker: read what the code does, use a demo account, and keep keys in environment variables, never in the code. New to GitHub? Start with the basics.

Use it with

Others of the same kind