Ronald Pearson of Brooklyn began swinging the sword Saturday at about 1:30 a.m. on 7th Avenue and 42nd Street, according to the NYPD.
Investigators say he also allegedly swung the sword at three police officers as they arrested him.
No one was injured.
Police say they uncovered two other weapons on Pearson.
He was charged with menacing, criminal possession of a weapon, and reckless endangerment.