Scientists began to understand the electron orbitals only in 1960. Before that there was no clarity about the cause of the spectrums of elements that scientists were able to identify.
So an attempt was made to group the patterns of the spectrums. This was done by identifying whether the lines in the pattern appeared sharp or diffused. Patterns that had the same lines as that of hydrogen were labeled principal. As scientists began to understand the causes behind the difference in spectrum lines the names used in spectrums recorded as photographs were continued as earlier to make things easier.
This led to the spdf or sharp, principal, diffuse and fundamental designations.