I notice people regularly talk about how much they have made per year in percentage terms for example "I made 20 % return last year"

Can anyone tell me how they calculate this

Is is a simple calculation of capital invested / return on investment

Taking return on investment calculated from gains made from dividends and shares sold minus trading costs and losses ( if any)

Many thanks