If my train is delayed on the way to school, does that count against me?

Not if you have a chien-shoumei-sho (delay certificate). It’s a paper slip you can pick up at the ticket gate right after you get off.  It shows the date and how long the delay was.  Give this to your professor.

Some train lines have introduced digital versions that you can print out from their website.