I want my graphs expanded and saved. Tried to do it in my codes and not sure if bbox_inches='tight' is doing what it needs to do, as my graph looks very small and the there seems to be a lot of space between the graph and the edge.
Below I have show snap of how the code is saving and how it looks if I manually expand and save the graph. How do I fix it?
fyi its not same as changing the size of the figures so (as someone suggested it to be and closed the question!)
import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
for x in range(3):
yy = np.random.randint(1,10,100)
plt.plot(yy)
plt.savefig('filename' + str(x) + '.png', bbox_inches='tight')
plt.figure()
plt.show()