2808 explained code solutions for 75 technologies


python-matplotlibHow to use figsize()


Using figsize() allows specifying figure size in inches:

import matplotlib.pyplot as plt
plt.figure(figsize=(3, 3))
plt.plot([4,2,11,2,1,20,25])
plt.show()ctrl + c
import matplotlib.pyplot as plt

loads Matplotlib module to use plotting capabilities

.figure(

change figure params

figsize

set figure size in inches (also set dpi to specify inch size in pixels)

.plot(

plot specified data

.show()

render chart in a separate window