Calculation guide
For investors reviewing holdings, income and trading assumptions.
Include only the costs you enter. Purchase averages use quantity weights; portfolio-return weights use beginning values over the same period. Reinvestment retains residual cash and states whether fractional shares are allowed. Rebalancing conserves cash after entered fees. Position size is an illustrative risk budget with no leverage or execution guarantee. Taxes and broker rules are not inferred.
Inputs
Quantity
Number of shares or amount in the selected package unit. Unit prices use a common base unit.
Buy price
Price per share for the indicated purchase or sale, before its separate charges.
Sell price
Price per share for the indicated purchase or sale, before its separate charges.
Buy costs
Total charge for this purchase or sale, not a charge per share.
Sell costs
Total charge for this purchase or sale, not a charge per share.
Worked example
| Input | Value |
|---|---|
| Quantity | 10 |
| Buy price | 100 |
| Sell price | 125 |
| Buy costs | 0 |
| Sell costs | 0 |
Formula:
10 × (125 − 100) − 0 − 0
Gain loss = 250.000000000000
| Result | Value |
|---|---|
| Gain | 250 |
| Cost basis | 1,000 |
| Net proceeds | 1,250 |
| Return on investment | 25% |
Interpreting the result
Ending value or receipts minus the relevant contributed money or costs. A negative value is a loss.
Money originally contributed or spent, before investment gains or losses.
How each input affects this example
Each row starts from the worked example and changes one input.
| Input | Original input | New input | Affected result | Original result | New result |
|---|---|---|---|---|---|
| Quantity | 10 | 11 | Gain | 250 | 275 |
| Buy price | 100 | 110 | Gain | 250 | 150 |
| Sell price | 125 | 138 | Gain | 250 | 380 |
| Buy costs | 0 | 1 | Gain | 250 | 249 |
| Sell costs | 0 | 1 | Gain | 250 | 249 |
