Machete attack caused panic on London Underground, court told

A machete-wielding man launched an unprovoked attack on a stranger in a train, a court hears.