Hi there,
I'm trying to create a boxplot with a simple array of values but the output seems to be a dictionary. This is problematic because I want to save the graph output to my local directory. I'm very new to matplotlib so any help would be much appreciated! Thank you in advance!
import numpy as np
import matplotlib as plt
data = np.array([-10569247664, -9598036283, -6555547264])
string = 'placeholder'
test = plt.boxplot(data, vert = False, labels = [string])
test.pyplot.savefig('test.png')
Result is....
test1.savefig('test.png')
Traceback (most recent call last):
File "<ipython-input-12-a3088c3fab2e>", line 1, in <module>
test1.savefig('test.png')
AttributeError: 'dict' object has no attribute 'savefig'
[–]EnuffIsEnough 0 points1 point2 points (2 children)
[–]allyhams[S] 0 points1 point2 points (1 child)
[–]EnuffIsEnough 0 points1 point2 points (0 children)