Spectroscopic and scanning probe studies of oxygen and water on metal carbide surfaces