Robberies, both those at gunpoint and without guns, have declined sharply in the District in the first half of this year, but a couple of recent incidents demonstrate how unpredictable the crime can be on city streets.

With the first six months of the year almost over, the number of robberies carried out with a firearm has fallen from 522 last year at this time to 266 this year. The reduction is almost 50 percent.

On the other hand, unsettling and unexpected events continue to occur. Robbers take cash and demand cellphones as well. In a more unusual incident, a robber demanded an article of clothing at gunpoint earlier this month on a street near both Gallaudet University and the H Street corridor.

Police said the robber approached the victim in the 900 block of 13th Street NE about 11:40 p.m. on May 7. A handgun was shown, and the robber “demanded the victim’s sweater,” police said.

The robber was given the sweater, and he fled. Police are looking for him. But the incident, along with another robbery recently reported, suggest the inherent limitations of advice commonly given for avoiding robbery.

Pedestrians are often cautioned against displaying cellphones or similar valuables on the street. But it is obviously more difficult to avoid being seen with shoes or clothes.

In the other incident, police said the victim was approached on Wednesday at 1:20 p.m. in the 6300 block of Fifth Street NW. The would-be robber demanded the victim’s shoes, police said.

The victim refused. He was assaulted, police said, but the robber fled empty-handed. A 14-year-old was arrested the next day, police said.

Police have cited efforts to remove guns from the streets as contributing to the decline in armed robberies.

However, robberies in which no gun was shown, such as the Fifth Street incident, have also declined compared with the first half of last year.

Based on police figures, the number of robberies without a gun reported last year from Jan. 1 through May 27 was 695. The corresponding figure for this year was 535, a 23 percent decline.