  I present the Automated Line Fitting Algorithm, ALFA, a new code which can
fit emission line spectra of arbitrary wavelength coverage and resolution,
fully automatically. In contrast to traditional emission line fitting methods
which require the identification of spectral features suspected to be emission
lines, ALFA instead uses a list of lines which are expected to be present to
construct a synthetic spectrum. The parameters used to construct the synthetic
spectrum are optimised by means of a genetic algorithm. Uncertainties are
estimated using the noise structure of the residuals.
  An emission line spectrum containing several hundred lines can be fitted in a
few seconds using a single processor of a typical contemporary desktop or
laptop PC. I show that the results are in excellent agreement with those
measured manually for a number of spectra. Where discrepancies exist, the
manually measured fluxes are found to be less accurate than those returned by
ALFA.
  Together with the code NEAT (Wesson et al. 2012), ALFA provides a powerful
way to rapidly extract physical information from observations, an increasingly
vital function in the era of highly multiplexed spectroscopy. The two codes can
deliver a reliable and comprehensive analysis of very large datasets in a few
hours with little or no user interaction.
