To create a corrected background spectrum, called outbkgspectrum.ds, from the source and background spectra, spectrum.ds and background.ds and keeping the intermediary arf files, as well as correcting the selected accumulation regions for bad pixels using the eventlist (eventlist.ds) used to create the spectra, the following example can be used.
backcorr srcspectrumset="spectrum.ds" bkgspectrumset="background.ds" outbkgspectrumset="outbkgspectrum.ds" withsourcepos=no keeparfs=yes witheventlist=yes eventlist="eventlist.ds"
Alternatively, to create a corrected background spectrum using the position in detector co-ordinates, the following could be used:
backcorr srcspectrumset="spec1.ds" bkgspectrumset="back1.ds" outbkgspectrumset="outbkgspectrum.ds" withsourcepos=yes sourcecoords="det" sourcex=-3917.0 sourcey=-3308.5 bkgdx=-2141.5 bkgdy=-2973.5