LOS ANGELES - Three Los Angeles teenagers were ordered Thursday to stand trial on murder charges in the slaying of a Chinese graduate student at the University of Southern California.

Judge M.L. Villar made the ruling in Los Angeles County Superior Court after hearing testimony from police and watching videos that a prosecutor said showed the fatal beating of Xinran Ji.

Ji, 24, was hit with a bat during an attempted robbery July 24 as he walked to his off-campus apartment after a late-night study session. He ran from his attackers, but they caught him a block away and continued the beating until he was on his knees.

Get Breaking News Delivered to Your Inbox

Jonathan Del Carmen, 19, Alberto Ochoa, 17, and Alejandra Guerrero, 16, will be arraigned on the murder count Jan. 29. A fourth teen, Andrew Garcia, 19, faces a preliminary hearing at a later date because of questions raised about his mental competency. All four pleaded not guilty after their arrests.

Deputy District Attorney John McKinney said the four were driving around looking for someone to rob when they saw Ji. One of the suspects said they targeted Ji because he looked Chinese and they thought he would have money.

The killing led to renewed concerns about the safety of USC's Chinese students, who make up about 40 percent of the school's large foreign population. Two other Chinese graduate students were murdered off campus in 2012.The school and Los Angeles police beefed up patrols after those killings and added surveillance cameras.

USC grad student Xinran Ji, 24, was found dead in his off-campus apartment on Thursday, July 24, 2014, after being attacked by at least three assailants, police said. CBS Los Angeles

Video cameras in the area caught footage of Ji being surrounded by the teens and struck with a bat. A second camera showed him running around the corner and then being caught a second time, where he was seriously beaten.

Ji managed to stagger home, trailing blood the whole way and was found dead in bed.

A couple hours after the beating, the four went to the beach, where Garcia, Ochoa, Guerrero allegedly robbed a tourist and attacked her friend.

Ochoa and Guerrero face trial in that attack on robbery, attempted robbery and assault with deadly weapon charges.

Del Carmen and Garcia could face the death penalty if convicted. Ochoa and Guerrero are charged as adults, but they can only face up to life in prison without the possibility of parole if convicted because of their ages.