I've taken the 3 am train to DC lots of times, and I would STRONGLY RECOMMEND staying on the NJ Transit train to New York and then boarding the train there. If it arrives on time, it usually boards around 2:40-2:45, and New York Penn Station is always busy, climate-controlled, and has a private seating area... some of the shops also stay open very late (if not all night). That way, you're also sitting around for a shorter period of time.
I've been at Newark Penn Station twice late at night, and I wouldn't recommend it... mostly because most of the station (including the main waiting area) is closed, so you're confined to a very small but well-patrolled area. Even trying to get a cab at 3 am was a little harrowing (and I lived in NYC for a long time).
On the other hand, there will definitely be other people hanging out at Newark Airport late at night (Terminal B has an all-night McDonald's that was crowded the last time I was there). So I'd go with EWR or New York Penn.