DODOMA, Tanzania — The number of people killed following a rare earthquake in the Lake Victoria region over the weekend has risen to 17, a Tanzanian official said Tuesday.

The 5.7-magnitude earthquake also left 252 people injured and 840 families homeless, George Simbachawene, the minister of state in the office of the president, told the National Assembly.

People died in collapsing homes. More than 1,200 houses need repair, and the government has closed two secondary schools that were heavily damaged by Saturday’s quake, he said.

A government statement said President John Magufuli cancelled a planned three-day state visit to Zambia to deal with the aftermath.

The quake was felt in western Kenya and parts of Uganda, which share the waters of Lake Victoria. Tremors also were felt in Rwanda’s capital, Kigali.

Damage assessment is still ongoing, according to the U.N. office for humanitarian affairs.

The quake was shallow, occurring at a depth of 10 kilometers (six miles). Shallow quakes generally tend to be more damaging than deeper quakes, as seismic waves from deep quakes have to travel farther to the surface, losing energy along the way.

The last notable quake in the region was in 2004 and measured 4.7. Recent earthquakes have caused secondary hazards such as landslides.