(CNN) As the investigation continues into why a female shooter opened fire at YouTube headquarters , data show that it's rare for women to carry out such shootings -- making Tuesday's incident unusual.

The shooting unfolded at the San Bruno, California, company premises when a woman shot and injured three people, and then apparently took her own life, officials said.

She appeared to have killed herself with a handgun, San Bruno Police Chief Ed Barberini said. The woman has been identified as Nasim Najafi Aghdam, a 39-year-old from San Diego, California.

The motive remains unclear.

Overhead video from CNN affiliate KGO showed a heavy police presence. People gathered outside, and one by one they were were frisked and patted down by officers. Several roadways near the building were closed to traffic.

Overhead video from CNN affiliate KGO showed a heavy police presence. People gathered outside, and one by one they were were frisked and patted down by officers. Several roadways near the building were closed to traffic.

People gather outside the building. One YouTube employee said people were trying to get out of the building "as fast as they could."

People gather outside the building. One YouTube employee said people were trying to get out of the building "as fast as they could."

Burlingame Police Chief Eric Wollman hands a dog named Kimba to a man who didn't give his name but said he worked for YouTube.

Burlingame Police Chief Eric Wollman hands a dog named Kimba to a man who didn't give his name but said he worked for YouTube.

Police walk outside the YouTube building. YouTube, which was founded in February 2005, quickly became the most well-known of several online video sites.

Police walk outside the YouTube building. YouTube, which was founded in February 2005, quickly became the most well-known of several online video sites.

Police respond to YouTube headquarters in San Bruno, California, after gunshots were reported there on Tuesday, April 3. At least three people were injured in a shooting, according to San Bruno Police Chief Ed Barberini, and the suspected shooter was found dead. Barberini said the dead woman appeared to take her own life but the investigation was just beginning.

Women are rarely behind active shooting incidents, according to data from an FBI study.

The FBI examined active shooter incidents, defined as "an individual engaging in killing or attempting to kill people in a confined and populated area" in the United States. Nine of the 220 incidents that had been identified by the FBI (about 4%) had female shooters, according to the FBI list from 2000 to 2016.

The women in those shootings were usually armed with handguns and opened fire inside colleges, businesses, their current or former workplaces, according to the list.

The latest incident at YouTube may not qualify as a mass shooting or murder as three of the victims are hospitalized with injuries.

But in general, there are less female shooters when it comes to firearm homicides, said Adam Lankford, criminal justice professor at the University of Alabama.

"Research shows that basically males commit more homicides than females, regardless of the subtype of homicide," Lankford said.

But in those incidents, female mass shooters are rare.

"Men commit the overwhelming majority of mass shootings for basically the same reasons they commit most violent crimes," Dewey G. Cornell, a licensed forensic clinical psychologist and director of the Virginia Youth Violence Project at the University of Virginia, wrote in an email to CNN on Tuesday night.

"Men tend to be more violent than women because of a complex interaction of evolutionary and psycho-social factors. Men tend to be more aggressive and less inhibited by empathy, and men in distress seem to be less willing to turn to others for help," he wrote.

None of the perpetrators behind the 28 mass attacks in 2017 were female, according to a report by the US Secret Service.

A study led by Lankford, published in the journal Violence and Victims , looked at 292 public mass shooters worldwide from 1966 to 2012 and found that only one of those was female.

When asked why women are rarely mass shooters, Lankford said: "We can't really answer that question of differences between male and female offenders because we don't have enough female offenders. The problem, or the good news, is we don't have enough female offenders for a statically significant sample."

But there have been cases where women have carried out deadly mass shootings.

Follow CNN Health on Facebook and Twitter See the latest news and share your comments with CNN Health on Facebook and Twitter.

A married couple, Syed Rizwan Farook, and his wife, Tashfeen Malik massacred 14 people at a holiday party in 2015 in San Bernardino, California. Farook had worked with the San Bernardino County health department, which was hosting the party when the attack took place. They were both killed in a shootout with police.

On January 30, 2006, Jennifer San Marco visited her former place of employment, a postal distribution center in Goleta, California, and fatally shot six employees after killing a one-time neighbor.

She then killed herself.