Colours and Line Styles
Style is not decoration; it carries meaning. Matplotlib lets you set the color (a name such as 'tomato', or a hex code such as '#1d8348'), the linestyle ('-' solid, '--' dashed, ':' dotted), the linewidth, the marker and the transparency alpha.
Two rules help readers. Use colour to separate things that are different (two shops) and keep one colour for one thing across every chart. And do not rely on colour alone: roughly one man in twelve cannot tell some colours apart, so a dashed line or a marker adds a second clue.
Which argument makes a line dashed?
Draw the line in green with a dashed style and circle markers, then print its colour, line style and marker on one line separated by spaces (use line.get_color(), line.get_linestyle(), line.get_marker()).
Finish the quick check (and any code exercise) to complete this lesson, or mark it done yourself.
Tip: use the left and right arrow keys to move between lessons.