The general consensus is that niche relevance matters a ton. I'm inclined to believe it, but I'm awfully skeptical.
Consider this recent study by Stone Temple:
https://www.stonetemple.com/links-remain-a-very-powerful-ranking-factor-study/
They didn't look at relevance
at all. Solely at links. And even just the number of links, with no regard to authority (much less relevance), mattered a great deal.
Or consider this note by Google that a site will
not be penalized for linking out, and the implication that linking out doesn't help:
http://www.thesempost.com/no-google-penalty-not-linking-site/
Putting the two together I think calls into question the absolute need for niche relevance.
Personally, I think niche relevance matters in two instances: (1) where the linking site is very low authority, and so the link is wholly disregarded unless it's high-quality and relevant and (2) the need for links / anchor text to bear some relevance to the text just to pass basic spam filtering. But this may only apply in cases of heavily spammy pages with an excessive number of links.
I think in most instances quality links beat "relevant" links. Personally I wish it wasn't so, and I know this is "so 2009" or whatever to say, but empirically I've yet to see anything showing "relevant" links making a great difference over "irrelevant" links.