risk_position-size
Calculate position size and dollar risk for a trade using fixed fractional sizing. Input account size, entry price, and stop loss to get number of shares to trade.
Instructions
Fixed fractional position sizing with risk/reward targets.
Use when calculating how many shares/contracts to buy given account size and risk tolerance. Provide account value, risk percentage, entry price, and stop-loss price. Returns: position size, dollar risk, and shares to trade.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| stop_loss | Yes | Stop loss price | |
| entry_price | Yes | Planned entry price | |
| account_size | Yes | Total account value | |
| risk_per_trade | No | Maximum risk per trade as fraction (e.g. 0.02 = 2%) |