An earthquake of 4.6 magnitude in western Canada was caused by fracking, according to the region's energy regulator.