Diffusion coefficients and trapping efficiencies measured with laser spectroscopy