We present an extensive comparison of models of structure formation with observations, based on linear and quasi-linear theory. We assume a critical matter density, and study both cold dark matter models and cold plus hot dark matter models. We explore a wide range of parameters, by varying the fraction of hot dark matter $\Omega_{\nu}$, the Hubble parameter $h$ and the spectral index of density perturbations $n$, and allowing for the possibility of gravitational waves from inflation influencing large-angle microwave background anisotropies. New calculations are made of the transfer functions describing the linear power spectrum, with special emphasis on improving the accuracy on short scales where there are strong constraints. For assessing early object formation, the transfer functions are explicitly evaluated at the appropriate redshift. The observations considered are the four-year {\it COBE} observations of microwave background anisotropies, peculiar velocity flows, the galaxy correlation function, and the abundances of galaxy clusters, quasars and damped Lyman alpha systems. Each observation is interpreted in terms of the power spectrum filtered by a top-hat window function. We find that there remains a viable region of parameter space for critical-density models when all the dark matter is cold, though $h$ must be less than 0.5 before any fit is found and $n$ significantly below unity is preferred. Once a hot dark matter component is invoked, a wide parameter space is acceptable, including $n\simeq 1$. The allowed region is characterized by $\Omega_\nu \la 0.35$ and $0.60 \la n \la 1.25$, at 95 per cent confidence on at least one piece of data. There is no useful lower bound on $h$, and for curious combinations of the other parameters it is possible to fit the data with $h$ as high as 0.65.