Subplot is the group of plots in one figure item.This type of plotting used to comparisons.While in your result shows maximum amount of figures shows that time you have use this type of plots.Subplot shows multiple plots in same Figure window.This subplot syntax as follows
row -> Represent you choose the row amount of plot
columns -> Represent you choose the columns of plot
plot-index -> Plot index
Following example shows the subplot best and simple example.
>>subplot(row,columns,plot index) ;
row -> Represent you choose the row amount of plot
columns -> Represent you choose the columns of plot
plot-index -> Plot index
Following example shows the subplot best and simple example.
>> x1 = rand(10,1);
>> x2 = rand(10,1);
>> x3 = rand(10,1);
>> x4 = rand(10,1);
>> subplot(2,2,1);plot(x1);
>> subplot(2,2,2);plot(x2);
>> subplot(2,2,3);plot(x3);
>> subplot(2,2,4);plot(x4);
>> x2 = rand(10,1);
>> x3 = rand(10,1);
>> x4 = rand(10,1);
>> subplot(2,2,1);plot(x1);
>> subplot(2,2,2);plot(x2);
>> subplot(2,2,3);plot(x3);
>> subplot(2,2,4);plot(x4);
here total 4 plots used so we split subplot 2,2,This split we choose and split,we also use following types of spiting plot,4,1, and 1,4,
No comments:
Post a Comment