All results seemed possible when the visitors set out on 171-5 in their second innings, leading by only 124. But Adil Rashid, unbeaten on 23 overnight, batted through the morning session, receiving good support from Jonny Bairstow (66) before solid contributions from the later order made the outcome inevitable, the Yorkshire all-rounder eventually missing out on a century by one run.
Yorkshire were eventually bowled out for 419 after a delayed tea and Somerset only had time to make 6-1 before the players shook hands.
Rashid had already made three of his nine first class hundreds against Somerset and looked sure to notch another after he and Bairstow had extended their sixth-wicket stand to 117.
The latter had also looked untroubled in making his second half-century of the match and had faced 138 balls, hitting 11 fours, when caught behind chasing a wide delivery from Alfonso Thomas with the second new ball.
By then Bairstow and Rashid had doubled the score, taking it to 234, and Yorkshire were well on course to avoid defeat. At lunch they had reached 275 for six and led by 228.
Tim Bresnan added 29 to his first innings century, helping to advance the score to 323 before falling lbw to Johann Myburgh looking to work the ball into the leg side.
Rashid had barely played a false shot in batting for four hours and 10 minutes when a rare lapse in concentration saw him flick a catch to Alfonso Thomas at backward square-leg off the occasional off-spin of Myburgh.
Having faced 198 balls and hit 12 fours, Rashid stood transfixed at his mistake before dragging himself off to the pavilion with the scoreboard reading 331 for eight.
The next wicket was a run-out as Liam Plunkett (21) failed to beat Jamie Overton’s throw to the bowler’s end from mid-on after he had been sent back by partner Steven Patterson attempting a quick single.
By then the Yorkshire lead was more than 300 and the outcome beyond doubt. Tea was delayed with nine wickets down, but Patterson and Jack Brooks still batted through to the interval which came with the total of 408 for nine.
The short final session saw 21-year-old Tom Abell collect a maiden first class wicket when Brooks was caught behind for 24, leaving Patterson 44 not out, before Glenn Maxwell earned the distinction of dismissing Marcus Trescothick when the home skipper carelessly lofted a catch to mid-wicket before the final handshake.
Yorkshire coach Jason Gillespie said: “To come away with a draw is a pass mark.
“However, we were well below par with the ball, barring Steven Patterson, who was outstanding, and we need to be more ruthless with our batting.
“A lot of players are getting starts without going on. Jack Leaning got a great hundred and Tim Bresnan did the same down the order, but it is our top six who need to be doing the business and we didn’t quite nail that.
“We can play a lot better, but I was delighted with the attitude shown in saving the game. We had a good chat in the dressing room at the end of play and know we have work to do.”