It seems like this is a good argument for not going public. You have to pay a 5% tax to bankers and sell shares to institutional investors at what often appears to be a 50% discount
But liquidity is valuable, and may be worth all the costs. The average P/E ratio for the stock market is ~15, while a small private business will only have a ratio of 3 or 4.
You can't compare the average nonpublic company with the average public company to come to the conclusion that companies should go public. You are including small plumbing businesses, etc. That realistically will never have a chance to go public, with large businesses that were successful enough to go public.
Or you can follow the Google model and do a Dutch auction.
Good luck finding an underwriter willing to do that if you're not a company like Google.