Can I use plotxx in a subplot?

2 views (last 30 days)
Max Campbell
Max Campbell on 30 Oct 2015
Answered: Walter Roberson on 30 Oct 2015
Im trying to create a subplot of two vertical profiles using the plotxx function for one, but the plotxx function wont work as a subplot. Is there a way that this can work??
Thanks for any help.

Answers (1)

Walter Roberson
Walter Roberson on 30 Oct 2015
No. plotxx() needs two axes, but subplot() is always a single axes.
plotxx is a File Exchange contribution. It is not written to expect that one might want to specify which axes are to be used. You could modify it to allow the axes to be passed in. But ultimately you face the problem that subplot() is always a single axes and plotxx needs two axes.
plotxx puts both axes in the same place, so it looks like there is a single axes. If that is satisfactory for you then your task is easier.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!