Ratio histogram

Hi, I have a histogram with three peaks, and I want to fit a flat line over each peak in order to extract the particle-to-anti-particle ratio. I tried several options, but none of them were successful. Could someone please give me some advice on how to proceed with this? I really appreciate the help.

Do you want to do something similar to this : Suggestion on how to remove background in invariant mass distributions