An analysis of millions of Twitter posts has gained some insight into emotional states throughout the day, finding commonalities across cultures.

People are generally more positive in the morning and weekends and turn more negative as the day wears on, before the mood rises again just ahead of bedtime, according to a study by Cornell University sociologists.

The study published Thursday in the journal Science, analyzed data from a two year period from 2.4 million Twitter users in 84 countries. It is entitled "Diurnal and Seasonal Mood Vary with Work, Sleep, and Daylength Across Diverse Cultures."

A computer program that analyzes text called linguistic Inquiry and Word Count was used to pore through 509 million tweets.

The program associates certain words with positive effects such as enthusiasm and alertness. Other words are associated with negative effects such as fear and guilt.

The program looked for mood changes daily, weekly and through various seasons.

“Though it might seem intutitive to suggest that the decrease in mood level during the midday hours is a result of workday-related stress … it turns out we see the same rhythmic shape on the weekends, when people typically are not working,” said Scott Golder, the lead researcher for the study.

“This suggests to us that something more enduring is going on, such as the effect of biological processes and sleep,” he said.

Golder, a graduate student, and sociology professor Michael Macy collected up to 400 public messages from each user between February 2008 and January 2010, while excluding those with less than 25 messages.

Golder said that that because the trends are seen every day of the week, for people around the world, “this suggests that there are biological processes driving these rhythms, and also that people are refreshed by sleep, overnight.”

The findings also suggest that most people have similar mood cycles across cultural norms. Four control groups involved the United States and Canada; the United Kingdom, Australia, Ireland and New Zeland; India; and English-speaking Africa were statistically similar.

In the United Arab Emirates, where the traditional work week runs from Sunday through Thursday, people generally had more positive moods on Friday and Saturday and lower positive moves Sunday through Thursday.

The study was funded by the National Science Foundation.