How to save file as pdf?

4 次查看(过去 30 天)
sam plant
sam plant 2018-12-13
编辑: YT 2018-12-13
imagesc(x,y,img), colorbar, %color plot
objectiveoutput = saveas(gcf,'objective.pdf'); %saving image as pdf
The above is a plot i wish to save however I am receiving the error that there is too many outputs.
Any help?

采纳的回答

madhan ravi
madhan ravi 2018-12-13
编辑:madhan ravi 2018-12-13
saveas(gcf,'objective.pdf') % without objectiveoutput =

更多回答(1 个)

YT
YT 2018-12-13
编辑:YT 2018-12-13
Well I don't think you can call saveas with an output argument which is why it gave you the error (see saveas documentation here). Just remove it and it will probably be fine
saveas(gcf,'objective.pdf');

类别

Help CenterFile Exchange 中查找有关 Printing and Saving 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by