3
$\begingroup$

I have problems with exporting figures using mathematica 9 and mathematica 10. My figure is created by ListLogPlot and when I use mathematica 9 I obtain very good quality but very huge files (2.7MB), if I just right click on the figure and save it as a graph. On the other hand, if I use Mathematica 10, then I always get a very low size image (23KB!) but its quality is much worse.

The problem is that, I can consider "options" which appers in the pop-up, when I right click and use "save graphich as", but playing with the options does not change the size of the image, in both mathematica versions. The version of the output file must be PDF and I tried to use "Export", which works only in mathematica 9 and gives me the same 23kb bad quality file in mathematica 10 even if I use Image Resolution-->2000, as an option. In mathematica 9, I am able to change the file size but the problem is that the x label gets wierd. In the original file they are like $10^{-4}$ , $10^{-3}$... and when i use export in mathematica 9 then the labels are 0.0001, 0.001, which take alot of unnecessary place.

Conclusion: I need to have acceptable quality and lower size pdf files from the figure I have. What are the options for me? I am really stuck here.

You can consider some sample images created with ListLogPlot as an example. I dont post a code here because I think I was able to explain my problem, (hopefully).

The following image (.jpg, I cannot put a .pdf here) is after using export with mathematica 9: the size became 1.483MB. whatever I do I am not able to change the size and quality. Short: mathematica 9 good quality big size and vice verse for mathematica 10. The

enter image description here

$\endgroup$
12
  • $\begingroup$ It always helps to post some working code to illustrate your problem (a picture is worth a thousand words..). Does adding the option "AllowRasterization" -> False to your Export[...,"PDF",..] reproduce the high resolution, large file size your obtained in V9? $\endgroup$ Nov 28, 2016 at 7:40
  • $\begingroup$ If you're looking to try to obtain high resolution (specifically in your axes labels and tick marks) with small file size, you can rasterize your graphics and keep vector axes etc, see here: mathematica.stackexchange.com/a/109652/6588 $\endgroup$ Nov 28, 2016 at 7:42
  • $\begingroup$ @Quantum_Oli "AllowRasterization" -> False or True doesnt change the file size either. I used mathematica 9 for that. $\endgroup$ Nov 28, 2016 at 7:45
  • $\begingroup$ Are you saying Export doesn't work at all in v10? In what way does it fail? Are there a huge number of points in your data sets? $\endgroup$
    – george2079
    Dec 1, 2016 at 15:51
  • $\begingroup$ Yes it fails and fails also in version 9. In 3D images the story maybe different. I have a 2D figure file as given in the question. With mathematica 9 I get image size of 2.7 mb and if I use export etc, I can get 1.4mb but it is still big. With mathematica 10 it is even worse. No matter what I do the size of the pdf file is 23kb.. just create a random 2d figure with ListLogPlot and simply try to save with different qualities.. $\endgroup$ Dec 1, 2016 at 15:55

1 Answer 1

1
$\begingroup$

I found the answer to my question. The problem is about the embedding fonts and can be circumvented easily by considering this post:

https://stackoverflow.com/questions/22570083/can-mathematica-be-instructed-to-print-to-file-smaller-pdf-files

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.