Sample Data For The Past 5 Years
Sample Data For The Past 5 Years
● Create a DataFrame
df = pd.DataFrame(data)
● Histogram of Population
plt.figure(figsize=(10, 6))
plt.hist(df['Population'], bins=5, color='teal', alpha=0.7)
plt.xlabel('Population')
plt.ylabel('Frequency')
plt.title('Distribution of Population Over the Last 5 Years')
plt.grid(True)
plt.show()