One of the classes was a set of three-year-olds, and one a set of four-year-olds.
Children whose friends were hard-working or extroverted gradually took on these personality traits over time.
But children whose peers were anxious or easily frustrated did not take on these traits.
Study co-author and psychology expert Dr Emily Dublin said kids are having a far bigger effect on each other than people may realise.
"Parents spend a lot of their time trying to teach their child to be patient, to be a good listener, not to be impulsive," Dr Durbin said.
"But this wasn't their parents or their teachers affecting them - it was their friends.
"It turns out that 3- and 4-year-olds are being change agents."
The new study is not the first to explore the contagious effects of personality traits.
A 2015 psychology study found that rudeness at work can be contagious as it travels from person to person "like a disease".
Researchers from Sweden's Lund University claimed that even petty behaviour, like leaving someone off an invite to a communal event or spreading rumours, can start the cycle off.
The study found that seeing a supervisor being rude to an employee was enough to cause people to be rude to those around them.
Often those who experienced rudeness would be uncivil to others.
Dr Eva Torkelson, a psychologist at Lund University, said the most common cause of people acting rudely at work was imitating others.
She said: "It's really about behaviour that is not covered by legislation, but which can have considerable consequences and develop into outright bullying if it is allowed to continue.
"An important finding from our studies is that those who behave rudely in the workplace experience stronger social support, which probably makes them less afraid of negative reactions to their behaviour from managers and colleagues."
The researchers questioned 6,000 people on the social 'climate' in their workplaces, which included offices, hotels and restaurants.
They found 75 per cent of those who took part said they had been subjected to rudeness at least once in the past year.
But the study also suggests that merely seeing other people being subjected to rudeness made it more likely that a person would treat their colleagues in the same way.
They said that many workplaces with strict social structures foster an aggressive environment.
Rudeness could include taking credit for the work of others, sending malicious emails or failing to give praise.
Dr Torkelson believes companies need to be more aware of the harm that rudeness in the workplace can do as it can spiral and damage the office. She said better training could help to combat the problem.
"When people become aware of the actual consequences of rudeness, it is often an eye-opener," she explained.
"And, of course, most people do not want to be involved in making the workplace worse."