Mastery table

This important stat is not well explained in the game, what does it do?

From my observation, with 10 mastery and the gear that i had at the moment, i did 30-50 damage to necromancer, while with 255 mastery and the same gear, i could do 55-75 damage to same monster.

If others may help in this matter, I am most interested about it.