Saveas or print: figure not appearing as desired (scatter points are half points, black lines appearing in a red region)
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Consider the following figure in Matlab
load matrices
%Rb, vertices_deg, vertices_comp
close all
patch([0 0 1],[0 1 0],[1 0 0],[0.8 0.8 0.8]);
axis equal
axis([0 1 0 1 0 1])
view(120,30)
hold on
T = delaunayTriangulation(Rb.');
K = convexHull(T);
patch('Faces',K,'Vertices',T.Points,'FaceColor','k','edgecolor','k');
hold on
scatter3(vertices_deg(:,1), vertices_deg(:,2) , vertices_deg(:,3),100,'o','filled','b')
hold on
patch(vertices_comp(:,1), vertices_comp(:,2) , vertices_comp(:,3),'red')
hold off
xlim([0 1])
ylim([0 1])
zlim([0,1])
box on
set(gca, 'ytick',0:0.2:1,'xtick',0:0.2:1,'ztick',0:0.2:1,'FontSize',13)
I would like to save this figure in a way such that:
- within the red region, I do not get the black lines that I can see in the Matlab output
- the blu scatter point is a full circle (and not half circle, as it appears in the Matlab output)
I tried two ways of saving the figure
saveas(gcf,'3.jpg')
print(gcf, '3.jpg', '-dpng', '-r300', '-painters')
None of these two gives me what I want. Could you help?
This is what I get with print and with saves
![3SAVEAS.jpg](https://www.mathworks.com/matlabcentral/answers/uploaded_files/245047/3SAVEAS.jpeg)
![3PRINT.jpg](https://www.mathworks.com/matlabcentral/answers/uploaded_files/245048/3PRINT.jpeg)
1 Commento
darova
il 26 Ott 2019
Can't replace it a bit?
T.Points = T.Points + 0.01;
vertices_deg = vertices_deg + 0.02;
vertices_comp = vertices_comp + 0.02;
Risposte (0)
Vedere anche
Categorie
Scopri di più su Printing and Saving in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!