Code covered by the BSD License  

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Highlights from
Interactive Peak Fitter, version 2.2

3.5 | 6 ratings Rate this file 7 Downloads (last 30 days) File Size: 36.1 KB File ID: #12557 Version: 1.0
image thumbnail

Interactive Peak Fitter, version 2.2


Tom O'Haver (view profile)


05 Oct 2006 (Updated )

A peak fitting program for time-series signals.

| Watch this File

File Information

A peak fitting program for time-series signals, with sliders to adjust the parameters conveniently. Uses an non-linear optimization algorithm to decompose a complex, overlapping-peak signal into its component parts. The objective is to determine whether your signal can be represented as the sum of fundamental underlying peaks shapes. Accepts signals of any length, including those with non-integer and non-uniform x-values. Fits Gaussian, exponentially-broadened Gaussian, Lorentzian, Pearson, and Logistic shapes (expandable to other shapes). Can be operated either by mouse-controlled interactive sliders or by keyboard shortcuts. Includes a self-contained demo. See for more information. Version 2.2, May, 2008, computes the area of each component peak using trapezoidal method.

MATLAB release MATLAB 6.5 (R13)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (11)
17 Feb 2010 Andre Guy Tranquille  
27 Dec 2008 Tom O'Haver

Tom O'Haver (view profile)

I've placed an updated version of this file at
as of December 26, 2008. It removes the "Warning" command that was causing an error in Matlab 7, and it eliminates the warning message about integer indexes with the colon operator. Tom O'Haver

Comment only
06 Dec 2008 Laurence Lurio

I could not get this to work. I tried the DemoInteractivePeakFitter program and got an error

??? Error using ==> warning
Unknown setting or incorrect message identifier 'exiting'.

I think this is the same error which Belen Rial Franco got.

Comment only
05 Sep 2008 Tom O'Haver

I've added ipf.m, a keyboard-operated version (without the sliders that have been giving some people problems), written as a single self-contained m-file.

Comment only
07 Apr 2008 Manjree Garg


This is a good interface. Is there any way to know how the fitting functions (e.g. Gaussian, Lorentzian etc.) are derived using half-width (which I guess is equal to three Sigma) rather than Sigma?

27 Feb 2008 Tom O'Haver

I apologize to John D'Errico and to the Matlab File Exchange for failing to attribute the fminsearchbnd function to John D'Errico. I was using an earlier version of fminsearchbnd, file date 6/7/2006. I did not realize that there was a subsequent newer version dated 9/25/2006. Evidently the earlier version did not have his name in the comments - I certainly did not purposefully cut it out. In retrospect I should have been more careful. I'll make the change as soon as practical.

Comment only
26 Feb 2008 Greg Fichter

This has an interesting user interface but the sliders kept crashing. It appears to incorporate John D'Errico's excellent fminsearchbnd function, but his name is clipped from the file. Sorry, but this is pretty shameful plagarism, even if the code worked.

21 May 2007 Walt Brown

Thanks for this program is very good. I would like to have a new profile about Doniach-sunjic but I´m not programmer. If you have it, can you send me?

18 Apr 2007 Tom O'Haver

Ann Brown:

Thanks for the feedback. Can you tell me which operating system and which version of Matlab you use? Also, what error messages you get when the program "crashes"? This information might be useful to me in developing the next version. Thanks.

Comment only
23 Mar 2007 Ann brown

Works very well, only sometimes it crashes or is very slow. Esspecially the keypressfunctionality sometimes has problems.

06 Feb 2007 Belen Rial Franco

I am trying this program using a 7.4.0 (R2007a) Matlab version installed under a Intel-based Mac but is not working.

??? Error using ==> warning
Unknown setting or incorrect message identifier 'Exiting:'.

Error in ==> InteractivePeakFitter at 21
warning('OFF', 'Exiting:')

Could you help me?

Thank you very much

09 Oct 2006

Bug fixes

09 Oct 2006

Bug fixes

17 Oct 2006

Add or update the screenshot

17 Oct 2006

Bug fixes

18 Oct 2006

Bug fixes

23 Oct 2006


31 Oct 2006


01 Nov 2006

bug fixes

10 Nov 2006


09 Mar 2008

bug fixes

Contact us