<SYSTEM_TASK:>
Given the following text description, write Python code to implement the functionality described below step by step
<END_TASK>
<USER_TASK:>
Description:
 Tutorial
Step1:  To import the pyplot library of the matplotlib simply do
Step2:  Plot in canvas with the plot command
Step3:  The above simply makes the canvas (in this tutorial since the matplotlib is loaded inline the plot is produced, while in a script the plot is not yet shown).
To show the plotted canvas simply ask pyplot to show the plot
Step4:  Title and labels
To set labels ask plt to modify the title, xlabel and ylabel
Step5:  Styles
To use styles import the styles library of pyplot
Step6:  and to use it
Step7:  One can also play around with the arguments of the plot command. For example
Step8:  Plot two lines and label them in the legend and also make a grid
<ASSISTANT_TASK:>
Python Code:
%matplotlib inline
Explanation: Tutorial: Plotting with matplotlib
This tutorial will give you an introductory tutorial to plotting data with matplotlib.
End of explanation
import matplotlib.pyplot as plt
Explanation: To import the pyplot library of the matplotlib simply do:
End of explanation
plt.plot([1,2,3],[4,5,1])
Explanation: Plot in canvas with the plot command:
End of explanation
plt.show()
Explanation: The above simply makes the canvas (in this tutorial since the matplotlib is loaded inline the plot is produced, while in a script the plot is not yet shown).
To show the plotted canvas simply ask pyplot to show the plot:
End of explanation
plt.title("Info");
plt.xlabel("X");
plt.ylabel("Y");
Explanation: Title and labels
To set labels ask plt to modify the title, xlabel and ylabel:
End of explanation
from matplotlib import style
Explanation: Styles
To use styles import the styles library of pyplot
End of explanation
style.use("ggplot")
plt.plot([1,2,3],[4,5,1])
Explanation: and to use it
End of explanation
plt.plot([1,2,3],[4,5,1], linewidth=5)
Explanation: One can also play around with the arguments of the plot command. For example:
End of explanation
x = [5,8,10];
y = [12,16,6];
x2 = [6,9,11];
y2 = [6,15,7];
plt.plot(x,y,'g',label='line one', linewidth=5); # a green line of width 5 called line one
plt.plot(x2,y2,'c',label='line one', linewidth=5); # a cyan line of width 5 called line two
plt.title("Info");
plt.xlabel("X"); 
plt.xlabel("Y");
plt.legend(); ## to make the legend USE THIS AFTER THE PLOT LINES
plt.grid(True, color='k');
plt.show()
Explanation: Plot two lines and label them in the legend and also make a grid:
End of explanation
<END_TASK>