the answer is not too difficullt. Warm air holds more moisture than cold air. Also warm air rises above cold air.
The air at the top of the room is the warm air. At a specific point (in height above ground) the air will be cold enough that it will release its moistue onto the cold window. Above that point the air is warm enough to hold all it's moisture thence no condensation