Study reveals key question for sleep quality