Re: @steelpillow and ImAlrightJack
What killed private railways as profitable enterprises was the advent of the diesel truck and better roads.
In the early days the government had to force railways to take paying customers as they wanted to focus on freight. The government nationalized the railways to keep some form of commuter service going.
Incidentally it wasn't railways that killed canals. Canals were used alongside railways up until the diesel truck. Railways have stuck around because they are the only (partial) solution to moving loads of people around in congested cities.