It is coldest above the level where jetliners fly, at 10-15 kilometers, the region from where it radiates most of its heat into space. That is why mountaintops are cold and the highest mountains have snow on their tops. Similarly, if for some reason the parcel is blown down, is is compressed again and heated by the compression. The motion of the rising parcel of air depends on its surroundings. As will be seen, this is where the humidity of air has an important effect.
Convection also operates on a global scale.
The greatest heating occurs near the equator, and air heated there rises and flows poleward, to cooler regions of the Earth. The rotation of the Earth greatly modifies this flow, by the Coriolis effect , as explained below. At the equator the east-west motion of the air matches that of the equator. Actually, the air loses velocity to friction with the ground. Therefore, the time it returns to the equator, it lags behind the rotating ground, and the average wind is easterly .