Search code examples
matlabplotsimulinksubplot

How to plot multiple functions in same figure (subplot) in Simulink?


Similar to what we can do with the subplot command in MATLAB to have many plots in a single figure, How can I plot different graphs in same figure using Simulink?

Note:

  • I am not asking about multiplotting which I already know how to do that using vector concatenate + scope but it gives me overriding plots. I am unable to find a way that I could have a separate subplot for each function.

Any help?


Solution

    1. Have multiple inputs for your scope (image shows right-click menu)

    1

    1. Show multiple plots from the layout menu (up to 16x16 plots) of the open scope

    2

    1. Voilà, subplots! As per the documentation, the first n traces will be shown in the first n subplots of the layout. Any traces which can't be shown individually will all be grouped within the last subplot.

    enter image description here