My theory is that anaerobic exercise, like squats, uses up ATP in the muscles. To replenish the ATP, muscle cells pull glucose from the bloodstream thus lowering your blood sugar level which leaves you feeling relaxed. If done prior to sleeping it can help you sleep through the night rather than wake up at 2am. There may be other benefits as well. That's my theory and I'm sticking to it.