matplotlib - How can I save a dendrogram plot from scipy.cluster.hierarchy dendrogram as a file? -


as doing agglomerative clustering, retain dendrograms rendered later review.

as far can see, scipy.cluster.hierarchy.dendrogram() function not return matlplotlib figure object can saved. best way of achieving this?

found out catch current figure

mathplotlib.pyplot.gcf() 

and save

mathplotlib.pyplot.savefig(filename) 

Comments

Popular posts from this blog

hibernate - How to load global settings frequently used in application in Java -

python 3.x - Mapping specific letters onto a list of words -

objective c - Ownership modifiers with manual reference counting -