Skip to content
Advertisement

Save Matplotlib figure as TIFF

Does anyone know how to save a Matplotlib figure as *.tiff? It seems that this format is not supported in Python, while the journals are quite often ask for that format.

I am adding some minimal code:

JavaScript

This works:

JavaScript

But this does not:

JavaScript

Advertisement

Answer

This is great! Thanks ot Martin Evans. However, for those who would like to make it happen in Python3.x, small fixes (since cStringIO module is not available; and I would rather use BytesIO)

JavaScript
User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement