TORONTO -- Maybe he is Lin-vincible.

Jeremy Lin did it again Tuesday night, this time leading the Knicks back from 17 points down and hitting the winning three-pointer with five-tenths of a second left.

Lin's run as the perfect point guard continued as the Knicks won for the sixth straight time, beating the Raptors, 90-87, at Air Canada Centre. Lin had 27 points and a career-high 11 assists to improve to 5-0 since becoming a starter.

After Lin drilled the game-winner, Amar'e Stoudemire and Tyson Chandler stood and stared at each other for a few seconds before jumping up and down and hugging each other at midcourt. After Rasual Butler's three at the buzzer was short and the horn sounded, Jared Jeffries picked up Lin.

"I'm just glad it went like this so we could calm the Lin-sanity down a little bit," coach Mike D'Antoni said.

Lin is scripting new chapters to this fairy tale every game. When asked if he believed what's happening to him, he said, "No."

advertisement | advertise on newsday

This time the Knicks trailed by 12 early in the fourth and by nine with just under four minutes left. They were down three with the clock approaching one minute.

Lin shook off his eight turnovers, plus his four missed free throws in the fourth quarter, and scored 12 in the final period. Down three, Lin drove, was fouled by Amir Johnson and converted the three-point play to tie it at 87 with 1:05 left.

Then in the closing seconds, after Chandler grabbed an offensive rebound and got the ball back to Lin, the point guard turned to look at D'Antoni. Lin wasn't looking to see if he should call timeout, either.

"Actually I looked back to ask him if I could get an 'iso,' " Lin said.

"He just called off the pick and said I'll take it," D'Antoni said.

The Raptors probably were expecting a pick-and-roll. But Lin, whose confidence is soaring, wanted the last shot. Jose Calderon backed off of him a little and Lin dribbled the clock down to the point where people on the Knicks' bench and on the court were screaming for him to shoot it.

Lin rose up and buried the three over Calderon and the very pro-Lin crowd cheered loudly as the Knicks celebrated.

"I'm thankful that my coach and teammates trust me with the ball at the end of the game," Lin said. "I like having it at the end of the game. I'm just very thankful."

"The guy has heart," Stoudemire said. "He played with such courage out there. I was amazed and am still somewhat amazed by the way he's playing."

This was only the second game Stoudemire played since Lin-sanity was born. Stoudemire missed the previous four games after the death of his older brother. He looked rusty early but had a strong second half. He finished with 21 points and nine rebounds.

advertisement | advertise on newsday

The Knicks (14-15) go for their seventh straight win and a chance at .500 Wednesday night at the Garden against the Kings.

Late-game defense also sparked this win. They held the Raptors to 12 points in the fourth when Iman Shumpert locked down Calderon.

The Raptors point guard had 25 points through three but didn't score in the fourth. Shumpert came up with a huge steal against Calderon with 1:31 left and went in for the slam that made it a three-point game.

After Lin tied it, Chandler blocked DeMar DeRozan, setting up Lin's three-point play. Leandro Barbosa's air ball from three set up the last-second shot that just added to the Lin saga. His teammates believed he was going to make the shot.

"There's no doubt," Jared Jeffries said. "The way this kid is playing right now, the way he has us playing, there's no doubt that he's going to score when he has to. He's going to make big plays consistently."