No, it wasn’t a St. Valentine’s Day massacre in Harlem Tuesday afternoon, but a police officer was wounded and the suspect he was pursuing was shot and killed.

Police Commissioner Ray Kelly arrived at the crime scene at the 145th Street and St. Nicholas Avenue subway station about 30 minutes after the shooting and immediately departed for New York Presbyterian Hospital/Columbia University Medical Center, where the officer was being treated for a wound on his arm.

Later, at a press briefing at the hospital, with Mayor Michael Bloomberg at his side, the commissioner explained what had happened.

Kelly said that the suspect, Michael McBride, 52, had been under surveillance after shooting the daughter of his ex-girlfriend on Monday in the Rockaways, in Queens. “McBride became the subject of an intensive search as a result,” he began.

McBride, Kelly continued, walked up 145th Street toward St. Nicholas Avenue from his home nearby and, possibly “to elude the police,” entered the station at its southeast corner then walked toward the northwest exit.

Apparently aware that he was being followed by a cop in plainclothes, McBride turned and opened fire, hitting officer Kevin Herlihy, 47, an 18-year veteran of the force.

Herlihy returned fire with a fusillade of bullets, hitting McBride in the chest.

McBride made it up one flight of stairs before he collapsed.

According to the commissioner, the shootout occurred in “an area that was fairly remote,” though it’s hard to envision any section that might be considered remote in that busy station.

McBride was rushed to the Harlem Hospital Center, where he was pronounced dead.

After fielding an innocuous question about his birthday, the mayor said his wish was that Herlihy has a speedy recovery.

“He will be able to walk out of here tomorrow and go home,” Bloomberg said.

Meanwhile, the 25-year-old woman McBride shot in the head is in critical condition at North Shore University Hospital in Nassau County. She was able to identify McBride, whom the police report said had a criminal record, as the assailant.

McBride was the fifth victim of the NYPD so far this year; in all of 2011, NYPD officers only killed 11 people.

Perhaps reflecting on the recent shootings, Kelly said, “Fortunately, we have another miraculous outcome today with an officer shot at close range, just 10 feet away.”