The man was subdued by passengers on the second bus after slashing four people [AFP]

A Japanese man has been arrested after a knife attack that injured at least 13 people, mostly junior and high school students, in a city northeast of Tokyo.

Unemployed Yuta Saito, aged 27, boarded two buses in Toride on Friday morning and attacked passengers with a knife before being subdued by civilians and arrested for attempted murder.

"The suspect got onto the buses and wielded a knife and slashed passengers in there," a police spokesman said.

The man knifed at least four people, while the others who were hospitalised were injured in the panicked rush to flee the crowded buses, media reports said.

"I wanted to end my life. It is true that I wounded people at random with a kitchen knife," Saito told police, according to Kyodo News Agency.

One of those injured in the attack has wounds that will require several weeks treatment in hospital, while the others are not seriously injured, Shireka Iyoka, a local fire department spokesman, said.

He said 11 of the injured were junior and high school students.

'Heard a scream'

The attacks occurred in front of Toride Station, in Ibaraki Prefecture, about 40km outside the capital.

"There were some 50 passengers on the bus when the man entered," one of the bus drivers told public broadcaster NHK from the crime scene.

"First, I thought it was a fight among students. But then I heard a scream and I thought this isn't normal. I saw the man wielding a knife, and I quickly opened the door to let the students flee. That's all I could do."

The driver of the second bus said: "I saw the students were running out of the bus in front of me as though they were flying, which wasn't normal.

"Then the man approached me with a knife. He glared at me and then went to the back of the bus, where he was subdued by the passengers."

The incident evoked memories of an attack that left seven people dead in central Tokyo in 2008. A man then slammed a lorry into a crowd of people in the Akihabara electronics district and began stabbing passers-by at random.

After the Akihabara incident and other high profile attacks, Japan toughened its knife laws. Regulations that went into effect last year ban double-edged weapons that are 5.5 centimetres or longer, shortening the limit from 15 centimetres.

Source: Agencies