  It is commonplace in cosmology to analyze fields projected onto the celestial
sphere, and in particular density fields that are defined by a set of points
e.g. galaxies. When performing an harmonic-space analysis of such data (e.g. an
angular power spectrum) using a pixelized map one has to deal with aliasing of
small-scale power and pixel window functions. We compare and contrast the
approaches to this problem taken in the cosmic microwave background and
large-scale structure communities, and advocate for a direct approach that
avoids pixelization. We describe a method for performing a pseudo-spectrum
analysis of a galaxy data set and show that it can be implemented efficiently
using well-known algorithms for special functions that are suited to
acceleration by graphics processing units (GPUs). The method returns the same
spectra as the more traditional map-based approach if in the latter the number
of pixels is taken to be sufficiently large and the mask is well sampled. The
method is readily generalizable to cross-spectra and higher-order functions. It
also provides a convenient route for distributing the information in a galaxy
catalog directly in harmonic space, as a complement to releasing the
configuration-space positions and weights. We make public a code enabling the
application of our method to existing and upcoming datasets.
