Rental properties areact more like bonds than equities - steady, fixed net income with the main risk being default risk (missed rent payments). Bonds are traditionally lower risk (meaning lower variance in returns) and so do not demand as high as a return as equities.
So to say one is "better" is comparing apples and oranges. You can compare returns for investments with similar risk, or compare risk for investments with similar returns, but it's not always clear how to compare investments with different returns and risk if they are proportional.