#data visulization #1. Line Plot #Line plots are used to visualize data points over time. import matplotlib.pyplot as plt # Example: Line plot for Sales over months months = ["January", "February", "March", "April", "May", "June"] sales = [12000, 15000, 17000, 13000, 16000, 19000] plt.plot(months, sales, marker='*') plt.title("Sales Over Time") plt.xlabel("Month") plt.ylabel("Sales ($)") plt.show()
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter