Interpolation of Histogram plot

5 次查看(过去 30 天)
is there any option to make interpolation between three histogram plot output and at the end we get one main histogram plot.
is there any matlab function avalible for this?
i used Histogramm2 function and genrate 3 plot. and i want to interpolate this three plot in one as answer.
  2 个评论
Steven Lord
Steven Lord 2021-3-29
is there any option to make interpolation between three histogram plot output and at the end we get one main histogram plot.
I don't understand your question. What do you mean when you say "three histogram plot output"?
Can you show us a picture or explain in more detail what data you have and what you want the final product of your code to be?
Mitulkumar Vasani
Mitulkumar Vasani 2021-3-29
in photo you will find three diffrent plot by histogram function and as value you can see three difreent row in second photo.
i want to again make interpolation between this three row and merge into one result and plot again a one histogram plot.
is this possible?

请先登录,再进行评论。

回答(1 个)

Pratheek Punchathody
编辑:Pratheek Punchathody 2021-4-1
As per my understanding, you have 3 different "histogram2" plots and you are looking for creating a single figure with all the 3 histogram plots merged together.
You can use "hold on" command to merge/ interpolate all the plots into a single plot and analyse the data.
Follow the following command to merge all the plots into single plot.
x = [1265 1315 2135 1595 1440 1231 1724 1613]; %some input data1
y = [1562 1058 9165 1462 1236 1286 1395 1111];
u = [125 115 135 195 140 121 174 163]; %some imput data2
v = [162 108 165 142 136 186 195 111];
m = [35 65 95 25 40 61 24 43]; %some input data3
n = [92 38 85 22 46 96 45 21];
histogram2(x,y,'FaceColor','g'); %plot histogram command
hold on; %waits and plots the next plot into the same plot as above
histogram2(u,v,'FaceColor','b');
hold on;
histogram2(m,n,'FaceColor','r');
hold off;
This above figure contains different histograms plotted together in the same figure.
You can also refer to the documentation on "histogram2" and "histogram2 properties" for more information. Also refer to the documentation on "hold" to know more about Retaining current plot when adding new plots.
Hope this helps..!

类别

Help CenterFile Exchange 中查找有关 Histograms 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by