How do astronomers distinguish the spectral lines? As a black body a star emits a continuous spectrum of light and other radiation. I've learned they are capable of knowing of what elements the stars are made of because of the spectral lines. But how do they distinguish those lines from other radiations?
The lines show as either peaks above the black body emission (for emission lines) or troughs below the black body emission (for absorption lines). Though stars more often have absorption lines and nebulae emission.