I am inspired from looking at the "show us your rail roads" thread and want to make a region that focuses on rail and mass transit. In my latest region, in certain areas, I noticed that the popularity of traveling by rail went downhill as the city grew. And my freight lines started growing weeds.
What's the best setup to have a thriving, functioning rail road for both commuters and freight.
I'd say you should probably limit your road connections considerably along the rail routes - that is, if you have a rail line along a strip of medium size cities, you can have all the connections you want, EXCEPT between the cities that the rail line goes through - you could probably get away with a single two-lane road connection without decreasing your rail line's usage too much though.
Nerdly_dood gives some good advice. I also recommend reading Nardo's Thoughts on the Game (http://sc4devotion.com/forums/index.php?topic=4114.0), it's a great source for realistic railway construction. It's based on the european style (gate crossings close in block sections, whereas they close individually in the US) but it gives some excellent pointers.
As far as functionality, the stations add a small cost in terms of transportation time. Keep this in mind when designing your transit networks. Road and rail have their own transit costs (can be thought of as speed). Basically, sims will always try to find the fastest route. They won't wait at a station (at each end) to get to a place if the track essentially parallels the drive. Also, rail can work for intracity transit, but El-Rail and GLR are also good things to try. Just remember that sims will take the shortest path (whether driving or by mass transit) to their destination, and high wealth sims will tend to drive if they can regardless of transit options.
Hope that helps.