I have a fund where, over the years, I have made multiple sales in-between multiple purchases. I can't find a worked example on how to assign the purchase costs to each shares sale, for the purpose of calculating capital gains tax, where sales and purchases are interleaved. So I made my own simple example (see table below). Can someone confirm that my calculations are correct?
To keep things simple, assume zero transaction costs, income units (not accumulation units), no dividend reinvestment, no purchases before March 1982, no sales before 6 April 2008, at least 30 days between any sales and another purchase, and ignoring any CGT allowance at this stage.
Purchases in years 2010, 2012 and 2014. Sales made in 2011, 2013, 2015 and 2016.
EDIT Improved colouring for better legibility and more columns totals added as per Bob's suggestion.