Export figure as EPS or PDF does not properly render some dotted lines; they become solid lines
20 次查看(过去 30 天)
显示 更早的评论
When exporting a figure containing three plots to EPS or PDF format, the line styles on the third plot only do not render properly. The dotted lines become solid (see first image).

When exporting to a raster format, there is no distortion (see second image).

Does anyone know a fix for this? I much prefer a vector format. It seems weird that the first two plots look fine.
0 个评论
回答(5 个)
Thomas Lindvall
2022-2-28
export_fig solved the problem for me:
1 个评论
Shyamprasad Natarajan Raja
2023-9-20
I had to create a PDF file from a figure with many data points. Plotting worked fine on matlab, but using exportgraphics() took a terribly long time. export_fig was almost instantaneous and produced the expected output. Great recommendation!
Georges Chahine
2022-4-29
编辑:Georges Chahine
2022-4-29
I was able to solve it by downsampling the data. Keep downsampling till you no longer have the issue. Example on 50% downsampling rows: B=A(1:2:end,:)
1 个评论
Ding Ding
2022-6-13
Downsampling works! It seems that if the sampling points on a curve are too dense, they will be processed into a solid line.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Printing and Saving 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!