×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

How grahically add plots?

How grahically add plots?

How grahically add plots?

(OP)
Hi,
i have two plots in one figure. Now i want to calculate the sum of those to plots and show it in the same figure.
Is it possible to add 2 plots graphically in matlab?
Does matlab take interpolated values?

RE: How grahically add plots?

It's not something built into Matlab, but it wouldn't be that difficult to code up.  You could use some uicontrols to kick off a curve-picking routine.

That routine could grab the xdata and ydata from the curves' handles (use gco to pick them).  Then you could use interp1 to interpolate one onto the other, do your addition and add the curve to the figure.

All in all, quite a neat little exercise to get you into handle graphics and uicontrols.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources