Filter löschen
Filter löschen

How to omit white spaces in non standard size matlab figure?

1 Ansicht (letzte 30 Tage)
Abhik Saha
Abhik Saha am 22 Jan. 2021
Bearbeitet: Abhik Saha am 22 Jan. 2021
I am using matlab R2017a version where I want to plot non standard size two figures in a particular way (see attached code). the problem is when I try to save the image in eps or pdf format then white spaces appear. please suggest a way in which I can generate non standard size plot with no white spaces for research purpose?
x = linspace(-2*pi,2*pi);
y = linspace(0,4*pi);
[X,Y] = meshgrid(x,y);
Z = sin(X)+cos(Y);
Z1=sin(X)+cos(Y);
h = axes('Position',[0.15,0.15,0.49,0.25]);
contour(h,X,Y,Z)
h = axes('Position',[0.73,0.15,0.25,0.25]);
contour(h,X,Y,Z1)
print(1,'-dpdf','filename.pdf');

Antworten (0)

Kategorien

Mehr zu Images finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by