comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Problem with Parinfo on Craig B. Markwardt's MPFITPEAK
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Problem with Parinfo on Craig B. Markwardt's MPFITPEAK [message #84681] Wed, 27 June 2012 05:52
Tito is currently offline  Tito
Messages: 16
Registered: March 2012
Junior Member
I am trying to fit Gaussians/Lorentzians with mpfitpeak on witch I know the center, the apmlitude and the Background offset and I want those 3 to be fixed and I am surching only the Sigma width. I tried this:

parinfo = replicate({value:0.0d, fixed:0, limited:[0,0], $
limits:[0.0d,0.0d]}, 4)
parinfo[0].fixed = 1b
parinfo[1].fixed = 1b
parinfo[2].limited[0] = 1b
parinfo[2].limits[0] = 0.005
parinfo[3].fixed = 1b
parinfo[*].value = [1.0d - stell_dep[i],xaxis[index[i]],0.0005, 0.0]

y_fit2 = mpfitpeak(xaxis[minus2+ind:index[i] + ind2],$
1-spec[minus2+ind:index[i] + ind2],$
p2, parinfo = parinfo)

But this jus is not working..... As I see it fix the centroid but all the rest of the parameters are not fixed and I am gettng terrible fit/fits.

Anybody know what I am doing wrong?

All the best!
Trifon
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: GRIDDATA - 3D mode
Next Topic: Re: locating the closest values?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 01:15:27 PDT 2025

Total time taken to generate the page: 1.83994 seconds