How do I make a video of a graph with axes and axes labels?
조회 수: 15 (최근 30일)
이전 댓글 표시
Hi
I would like to make the video of a graph which includes the axes labels. It seems that it by default does not. Can someone help me get the whole graph with axes and axes labels in the figure. Here is an example where it does not work as intended since the axes labels are not fully shown.
close all; clear all;
writerObj = VideoWriter('peaks.avi');
writerObj.FrameRate = 5;
open(writerObj);
Z = peaks; surf(Z);
axis tight
set(gca,'nextplot','replacechildren');
set(gcf,'Renderer','zbuffer');
xlabel('x label')
ylabel('y label')
zlabel('z label')
for k = 1:20
surf(sin(2*pi*k/20)*Z,Z)
frame = getframe;
writeVideo(writerObj,frame);
end
close(writerObj);
winopen('peaks.avi')
Thanks in advance :)
채택된 답변
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Image and Video Ground Truth Labeling에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!