IMPERIAL BEACH  A sheriff’s SWAT team ended a four-hour standoff with the arrest of a man who assaulted a deputy, then barricaded himself in a neighbor’s bedroom in Imperial Beach Friday, authorities said.

Officials said Richard Allen Perez, 30, tossed furniture and household goods out the second-floor window at deputies, and they fought back by spraying the unit with numerous pepper ball rounds.

Sheriff’s officials were investigating conflicting reports whether a shot was fired during the incident at the condominium complex on Holly Avenue near 13th Street.

The confrontation began just before 7 a.m. when neighbors called 911 to report yelling and screaming coming from a home, said sheriff’s spokeswoman Melissa Aquino. A deputy contacted the man, later identified as Perez, and was assaulted. The nature of the attack was not released.

The deputy was taken to a hospital with minor injuries, Aquino said.

Perez fled. Deputies went door to door for about an hour before learning Perez was holed up in a unit in a nearby complex.

Resident Jenece Nelson said she was home with her 9-year-old son about 8 a.m. when she was woken by the sound of a sheriff’s helicopter broadcasting a suspect description. Authorities told residents to be on the lookout for a felon described as a Latino man, 30 years old, heavily tattooed and wearing a blue shirt, she said.