More on Stellar Spectra

The role of temperature comes from realizing that electrons in different elements will be excited to orbits more distant from the nucleus at different temperatures, hence giving different spectral types for stars of different temperature: (From U. Tenn Ast. 162, http://csep10.phys.utk.edu/astr162/lect/stars/spectra.html)

Excitation of different spectral lines vs. temperature

two representations of an absorption spectrum

dependence of hydrogen absorption strength on stellar type See in these spectra how the hydrogen absorptions (the series of strong lines that dominate the spectra) are weak at O6 and strengthen dramatically to A1, then start to weaken slowly to A9/F0.