I guess I should emphasize that I want to keep the axes, titles, and annotations of each figure separate, i.e. I am not trying to plot all the histograms on top of each other. I want to create a figure object that has multiple sets of axes.
how to make a movie of multiple figures simultaneously using getframe
4 views (last 30 days)
Show older comments
I have four 2d histograms, I have turned each into a time sequence of 1d histograms and made four movies using getframe, movie, and movie2avi. Is there a way to merge them so I can see all four histograms in one movie? I have never seen a way to merge multiple figures into a single layout the way you can do in other programs e.g. Igor Pro (Wavemetrics). I would rather not export my figures, merge elsewhere, and then import them back. I imagine there might be a sneaky way to merge the cdata and colormap matrices before calling movie(M), but I would definitely prefer a general method of merging figures together.
thanks in advance
Accepted Answer
Walter Roberson
on 25 Aug 2011
Are the colormaps compatible? If so then you should be able to use subplot(), but I would suspect that embedding each within a uipanel() would be less work (all the uipanel would then parent to the single figure.)
If the colormaps are not compatible then it gets trickier.
Are you producing your histograms using hist() [specifically] ? If so then if I recall correctly they get produced a bit differently than otherwise.
If you are producing your histogram by using one of the bar() calls, then you end up with a hggroup object underneath which there is one patch object per column of original data. For example if you have 5 groups of 3 bars each, then that would reflect a 5 x 3 data matrix, and there would be 3 patches produced. The coding to go in and zap the patch color from pseudocolor to RGB is relatively short. You would do that because objects that are in RGB color have no colormap clash, so you can have several such objects on the same "figure" (which might have been subdivided in to uipanel)
More Answers (0)
See Also
Categories
Find more on Graphics Object Properties in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!