Field and anisotropy effects in spin glasses. I. The collinear case