Similar statements are in Ricardo's obituary in the Sunday Times on 14 September 1823 and Paul Samuelson's more recent articles about Ricardo.
This story might be described as mythical and also involves some confusion between David Ricardo and Nathan Rothschild, also supposed to have made a large fortune over news from Waterloo, especially as one of the sources referred to Mr. R.
Wilfried Parys has an detailed paper, Samuelsonian legends about Ricardo’s finances lack historical evidence , trying to explain the position in more detail. Ricardo was extremely rich before Waterloo having profitably financed Government borrowing. He also financed a particular issue in June 1815 where the price was agreed before Waterloo and which he sold a profit after the battle, but he had undertaken similar transactions before. Since he sold before the news from Waterloo became general knowledge, he actually missed half of the rise.
So the evidence is not there of a £1 million profit for Ricardo in a single speculation, though there is evidence of a series of smaller profits over several years which made him wealthy and enabled him to retire to Gatcombe Park and purchase a rotton borough parliamentary constituency.