* Hammer beats Trott in omnium to avenge Olympic defeat
* Botticher defeats Dmitriev to complete sprint double
* James wins last-event Keirin for her fourth medal (Updates after final race)
MINSK, Feb 24 (Reuters) - Britain's Rebecca James won the last event on the track for her fourth medal and second gold to become the most successful rider of the world cycling championships on Sunday.
The 21-year-old from Wales, who claimed the women's sprint crown on Saturday, took the lead midway through the eight-lap Keirin race and maintained her advantage all the way to the finish.
China's Jinjie Gong won silver and Cuba's Lisandra Guerra the bronze after German Kristina Vogel, one of the pre-race favourites, crashed just before the final lap.
"It was a lot of pain (riding from the front)," said James, who goes home with two golds and two bronzes she earned earlier in the week in the team sprint and the 500 metres time trial.
"I would have been glad to find someone's wheel but there was no choice, but I just kept going and it paid off."
Earlier, experienced American Sarah Hammer and young German Stefan Botticher also clinched their second golds, prevailing in the women's omnium and the men's sprint respectively.
Hammer, who sealed her fifth world title in the individual pursuit on Wednesday, beat her main rival Laura Trott on the last day of the five-day championships to avenge her Olympic defeat to the British rider.
"This is my sixth gold (overall) and I'm so excited with my win," the 29-year-old Californian, the only American who made the trip to the Belarus capital, told reporters.
"At the Olympics Laura was ahead of me but I always try to win, that's why I trained hard. Now I'm really, really happy.
"I pursued three events here - it was a bit crazy, so I'm delighted to get two gold medals," added Hammer, who also contested Friday's 10-km scratch race.
Hammer, the overnight leader after the first three events on Saturday, extended her advantage after winning, as expected, her speciality - the pursuit.
She was fourth in the scratch race and sixth in the final discipline - the time trial - but had built up enough of a lead to win by four points over Trott, who took silver just ahead of Australian Annette Edmondson.
Botticher beat Russian Denis Dmitriev in the final to complete a sprint double after winning the team title with Rene Enders and Maximilian Levy on Thursday.
"Honestly, I've never even imagined winning two gold medals," said the 21-year-old Botticher, who was competing on the junior circuit two seasons ago.
"My main objective was to do well in the team sprint, but after we won the gold there I had less pressure on me during the individual competition. The second gold was a nice bonus."
Vivien Brisse and Morgan Kneisky of France claimed gold in the 50-km Madison race, consisting of 200 laps around the wooden oval of the newly-built Minsk velodrome.
Spain's David Muntaner and Albert Torres won silver thanks to finishing first on the final spurt, with German duo of Theo Reinhardt and Henning Bommel taking bronze.
Britain topped the overall medals table with five golds, two silvers and two bronzes ahead of Germany, who had three golds, three silvers and two bronzes. Australia, France and the United States won two golds each. (Reporting by Ruslan Batenkov; writing by Gennady Fyodorov; Editing by Clare Fallon)