Trouble using findpeaks : Too many output arguments.
7 views (last 30 days)
Show older comments
Pragya Srivastava
on 1 Dec 2014
Commented: Star Strider
on 1 Dec 2014
Hello, I am using [pkt,lct,wt,ct]=findpeaks(data) to find the peakheight, location, width and prominence of the peaks in my data. This gives me error message 'Too many output arguments'.
However, When I am using [pkt, lct]=findpeaks(data), there is no error. Please suggest the solution. Please help.
0 Comments
Accepted Answer
Star Strider
on 1 Dec 2014
The ‘expanded’ findpeaks return syntax is new to R2014b. The online documentation defaults to the most recent release, so will not necessarily be correct for prior releases as well.
2 Comments
Star Strider
on 1 Dec 2014
My pleasure.
If I remember correctly, MATLAB licenses cover the full year, so you should be able to download and install R2014b as part of your current license. That will give you access to the new version of findpeaks.
Don’t uninstall R2014a, because the HG2 graphics in R2014b take a bit of time to learn. HG2 also has less flexibility than previous versions of MATLAB graphics (at least in my opinion).
More Answers (1)
Image Analyst
on 1 Dec 2014
What version are you using? Is it possible that the 3rd and 4th outputs were added in a later version than you have? What does the help documentation say - does it list all 4 output arguments? What does this say
which -all findpeaks
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!