Correlation between the structural and optical properties of spontaneously formed GaN nanowires: a quantitative evaluation of the impact of nanowire coalescence