I have been trying to adapt some of the previous suggestions on other questions similar to my problem but I haven´t been able to solve my problem so far. Best wishes

  • $\begingroup$ The question as it is, gives no clues about what to do! $\endgroup$
    – Cesareo
    Nov 29, 2020 at 17:59
  • $\begingroup$ Yes, I would like to delete the question. It could not get solved and other threads are very similar and have very detailed and excellent solutions to similar problems. For this particular question the solution was not working. Therefore I would ask to delete the whole thread, please $\endgroup$
    – Fred
    Nov 29, 2020 at 21:55

1 Answer 1


It looks like this question can be answered following the answers in this discussion: "Multi-peak fitting for peak position".

I was too lazy to figure out a basis with the functions you want to fit. (You have listed many parameters.) So, I used the Gaussian function in this answer:

gaussian[amp_, pos_, fwhm_, x_] := 2^(-((4 (-pos + x)^2)/fwhm^2)) amp

Here are the obtained fits:

enter image description here

If you can come up with a reasonable basis using code similar to this one:

aBFuncs = 
     pos -> gaussian[amp, pos, fwhm, x], {amp, {1}}, {pos, Min[data[[All, 1]]], Max[data[[All, 1]]], 0.05}, {fwhm, {0.3, 0.1}}]];

then you should be able to get the fits you want.

  • $\begingroup$ Thank you very much for your help! The data is going from top to bottom, so the peaks are not upwards but going from the top downwards. $\endgroup$
    – Fred
    May 11, 2020 at 22:30
  • $\begingroup$ @FredWeker "The data is going from top to bottom, so the peaks are not upwards but going from the top downwards." -- It should not matter if the function basis is chosen right. $\endgroup$ May 12, 2020 at 12:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.