Multiple Line chart in Python with legends and Labels: lets take an example of sale of units in 2016 and 2017 to demonstrate line chart in python. Line 4: Displays the resultant line chart in python. So the output will be . Line 3: Plots the line chart with values and choses the x axis range from 1 to 11.