“We will avenge the killings", shouted the crowd of about 1000 mourners in the southern city of Karachi, on Saturday.
At least 25 vehicles were torched and a police post and three gas stations attacked with stones before police intervened with teargas.
Two or three gunmen on a motorcycle opened fire on the bus carrying the six to a mosque for Friday prayers. Five were killed on the spot and a sixth died in hospital.
Most of the dead and wounded were employees of Pakistan's Space & Upper Atmosperice Research Commisson, using a company bus. No group has claimed responsibility for the attack.
Witnesses said some of the protesters at the funeral suffered minor injuries in scuffles with police, who struggled to control the crowd. Police said they had detained at least eight people.
"The situation is now under control," city police chief Tariq Jamil said.
Hundreds of people have been killed in sectarian violence in Pakistan in recent years. In July this year, at least 57 worshippers were killed in an attack on a mosque in the southwestern city of Quetta.
Pakistan is a predominantly Sunni Muslim country, with Shias accounting for about 15% of its 149 million people.