The "official" NTP client software simply increments stratum by one for each connected server. That is all servers connected to a Stratum 0 server are Stratum 1, all servers connected to them are Stratum 2, and so on.
In general this is sensible. You most certainly do not want to increase your stratum by 1 per network hop, as this is:
- unreliable, since not all hops will show up in traceroute anyway, and
- would result in crazy stratum numbers, it is not uncommon to be 10 or more traceroute hops away from your NTP provider.
In general the NTP protocol is designed to be resilient to "network distance", that is RTT are not terribly relevant. What is much more relevant is the consistency of those RTTs.
Edit: To address one of the comments, the normal "remote" configuration has the local clock as being stratum 12. In general, if a server is being synced up against a stratum 0/1/2 server then it should be considered more reliable than the clock on the computer's motherboard. This means that it should have a stratum less than 12, otherwise "normally configured" clients will believe that they are more reliable.