A method and an apparatus of automatically determining which type of treatment is most appropriate for a patient, the method comprising transforming one or more time domain measurements from the patient into frequency domain data representative of the frequency content of the time domain measurements, processing the frequency domain data to form a plurality of spectral bands, the content of a spectral band representing the frequency content of the measurements within a frequency band, forming a weighted sum of the content of the spectral bands, with different weighting coefficients applied to at least some of the spectral bands, determining the type of treatment based on the weighted sum.