A man armed with a knife has set a train carriage on fire in Switzerland, leaving six people, including a six-year-old child, in hospital with stab wounds and burns.

The 27-year-old Swiss citizen carried out the attack on a train travelling near the border with Liechtenstein and was also injured, regional police in Saint Gallen said.

The motive for the attack was not immediately known. However, it is the latest in a series of similar assaults in Europe over the past month, including an attack by a 17-year-old Afghan asylum seeker who injured five people with an axe and a knife on a train in Germany.

Swiss police said the possibility of terrorism was unlikely. "A terrorism background still seems very, very far-fetched," the spokesman said.