gold ends new year's eve and 2018 in the red, but books 7% quarterly gain as stocks swoon