JACKSON, Miss. — Children are more at risk of contracting the coronavirus at a social gathering than in a classroom or child-care setting, according to a study of nearly 400 youths in Mississippi.

Researchers surveyed patients younger than 18 who had tested positive for the virus in emergency departments and outpatient health facilities during September, October and November.

Compared with children who tested negative, those who tested positive were more likely to have attended gatherings and have had visitors at home, the researchers found.

Additionally, parents or guardians of children who were infected were less likely to report wearing masks at those gatherings.

“Household contacts versus a contact at school appeared to be more important in a child’s risk for being infected,” said Dr. Charlotte Hobbs, professor of pediatric infectious diseases at the University of Mississippi Medical Center and the study’s lead author.

State Epidemiologist Dr. Paul Byers, who contributed to the study, said the report highlights what health professionals have seen “played out time and time again” during the pandemic.

The study also said that the “lack of consistent mask use” in schools led to some spread of the virus.

Hobbs said protecting children from the coronavirus is essential to keeping the state’s schools and day-care centers open.

The study was conducted in partnership with the U.S. Centers for Disease Control and Prevention and was published this month in the CDC’s Morbidity and Mortality Weekly Report.