position-sizer
Installation
SKILL.md
Position Sizer
Overview
Calculate the optimal number of shares to buy for a long stock trade based on risk management principles. Supports three sizing methods:
- Fixed Fractional: Risk a fixed percentage of account equity per trade (default: 1%)
- ATR-Based: Use Average True Range to set volatility-adjusted stop distances
- Kelly Criterion: Calculate mathematically optimal risk allocation from historical win/loss statistics
All methods apply portfolio constraints (max position %, max sector %) and output a final recommended share count with full risk breakdown. The default output is whole shares. Use --fractional only when the user's broker supports fractional shares for the security and order type.