not valid.
The poster compares a single $4k investment in the S&P vs a single $4k investment as a down payment on a $20k house.
The $4k in the S&P would be worth $480k today (120x).
But the $4k in the house would not be only worth $285k (the median home price today). Cash flow from rental income and equity from appreciation would be leveraged to buy additional properties over the 50 years. Properties would be sold tax free using a 1031 exchange into new properties. Mortgages would be paid off to create even more cash flow. Investment income taxes would be offset by depreciation of properties.
That single $4k investment in a $20k home in 1968 could very easily be a portfolio of 15-20+ homes, duplexes, and apartment buildings today worth many millions of dollars.
Sure, real estate is a much more of an active investment that requires hands on participation. It's not just sitting in a brokerage account that you review the statements for every month. But it has the potential of earning much higher returns than the S&P 500.