i'm with djhope, although houses aren't that 'bad' an investment, take a look at the fidelity market chronical, which compares cash, property, bonds and shares. Over a 70 year period property is second, shares are first, and cash is last.
Lets also not forget inflation, my large mortgage is happily inflating away over the years, typically over 25 yeras your mortgage value at least halves in value. Rent of course generally keeps pace with inflation.
For a true comparison you need to look at the total Cost of Ownership over a 25 year period (heck you could even assume that you move a couple of times), compared to the to Cost of Renting over the same 25 year period (include the cost of planned and forced moves). An over-riding factor here will be inflation, money in your bank gets inflated away, money you borrow (which you probably gear up with your savings) gets inflated away, rent rates should keep up with inflation, and house prices should beat inflation (in the long run!). I honestly don't know which one will be cheaper but I do know that it will be nothing like the stark figures given at the start of this thread.