Obscuration by cold matter is frequently observed in a variety of X-ray sources. With the improved sensitivity and energy resolution of the new generation of X-ray detectors, such as those aboard ASCA, it may not always be possible to neglect electron scattering for column densities much greater than ~1023 cm-2. We derive simple, approximate, analytic expressions for a spherical geometry, which enable the transmitted flux to be corrected for nonrelativistic Compton scattering. The method allows the use of arbitrary element abundances, photoelectric absorption cross sections, and input spectra and is computationally fast enough for use in a spectral fitting code. The approximations can be used for column densities up to ~5 × 1024 cm-2. The maximum observed energy for which the approximations are valid depends on the column density and is ~18.5 keV for NH = 1023 cm-2 and ~10 keV for NH = 5 × 1024 cm-2. The model provides a significantly improved description of the transmitted spectrum compared to the usual model, in which only attenuation due to the absorption opacity is considered, and scattering is neglected altogether. The latter leads to errors in the transmitted spectrum that can exceed 1 order of magnitude, especially around the Fe K edge.