|Specsavers County Championship Division One, Cooper Associates County Ground (day four):|
|Yorkshire 202 & 283: Ballance 98*, Handscomb 70; Bess 5-80, Leach 3-53|
|Somerset 224 & 258: Hose 68, Davies 59; Patterson 3-28|
|Yorkshire (20 pts) beat Somerset (4 pts) by three runs|
Somerset fell agonisingly short of a first County Championship victory of the season as Yorkshire pulled off a thrilling win by three runs at Taunton.
Jamie Overton put the hosts on the brink of their target of 262 with a six off Adam Lyth, but was last man out two balls later, caught at mid-wicket.
Earlier, Adam Hose (68) and Steven Davies (59) had both passed fifty.
Craig Overton (34) and Lewis Gregory (26) took Somerset to 231-6 before Ryan Sidebottom (3-59) and Lyth cleaned up.
Somerset, who missed out on a maiden County Championship title to Middlesex on the final day last season, are now winless in six matches in 2017.
After Championship debutant Hose and Davies had extended their fifth-wicket stand to 118 in the morning session they had reduced the victory target to less than 100.
Despite both falling in quick succession, Gregory and Overton continued to play sensibly either side of lunch to put Somerset within 31 runs of victory.
But a brilliant three-wicket spell from Sidebottom accounted for Gregory, Overton and Jack Leach - and Karl Carver clung onto Jamie Overton to seal Yorkshire's third win of the campaign.
One-Day Cup next on the agenda
Yorkshire and Somerset now immediately turn their attentions to the One-Day Cup, as both host quarter-finals on Tuesday.
Somerset play Nottinghamshire at Taunton (11:00 BST), while the Tykes take on Surrey at Headingley (14:00 BST).
The winners of the Somerset-Notts game will meet Essex at Chelmsford on Friday (16 June, 13:30 BST), while Worcestershire will host the winners of the Yorkshire-Surrey semi-final at New Road on Saturday (17 June, 11:00 BST)
Yorkshire's next Championship game is at Lord's, starting on Monday, 19 June, against reigning champions Middlesex (11:00 BST), while Somerset's next game is the day-night match against Hampshire at Southampton, starting on Monday, 26 June (14:00 BST).
Somerset director of cricket Matthew Maynard told Eyes On Events Radio Bristol:
"We encourage our young players to be positive, so it wouldn't be fair to criticise them for getting out to attacking shots. This match demonstrated the fine lines between success and failure.
"There is work to do on our Championship cricket, but getting so close to a target of 262 suggests that we are not far away
"The players are gutted in the dressing room. Now we have to pick them up for a big cup game against Notts. But Adam Hose acquitted himself really well on his Championship debut."
Yorkshire coach Andrew Gale told Eyes On Events Radio Leeds:
"What a whirlwind game, After Huddersfield Town's penalty shoot-out win, it's certainly not good for my ticker.
"Gary Ballance's captaincy was excellent. I might have been tempted to take the second new ball, but he stuck with the old one and Ryan Sidebottom did the business for us again.
"You can't replace a player like Ryan. We weren't at our best as a team, but we have got the right result and now we can take the momentum into the Royal London Cup game against Surrey."