When I started in astronomy, we were publishing luminosity functions for M dwarfs based on a few photographic sky survey plates. That is, we would count hundreds or perhaps a few thousand stars in a few hundred square degrees. This was just the 1990's, not that long ago. I was reflecting on how quickly things have changed. Here's John Bochanski et al.'s new paper on Sloan Digital Sky Survey K and M dwarfs:
The analysis incorporates ~15 million low-mass stars
I was really taken by their Figure 13 where you see how beautifully they can measure how the density of stars drops above the Galactic Plane (that distance is called Z here) and radial distance from the Galactic Center (R).
It's just a wonderful analysis, one of many coming out of the digital sky surveys. Of course, the luminosity and mass functions -- that is the number of stars that have a given luminosity or mass -- is not that very different from the old analyses.