For automatically fitting a Gaussian to an emission line over an entire raster and analysing the results, the following routines are available:
If you want to average a spatial region and fit multiple lines in the spectrum, then the following tutorials describe available software: