Suppose I have a dataframe like this with columns year, months, max, min:
year Month max mix 0 2000 1 3.0 0.30 1 2000 2 3.7 0.70 2 2000 3 3.6 0.60 3 2001 1 2.4 1.40 4 2001 2 2.9 1.30 5 2001 3 3.1 1.55
So for each year I have 12 months, and for each month I have or more columns holding numerical data. For each year separately I’d like to make a plot showing how max and min values vary with each month. In the example here, I have 2 years (2000 and 200) so I need 2 separate plots, showing 2 line graphs (or bars) on each, corresponding to max and min columns (vertical axis) and “month” variable on horizontal.
How can I do this? Ideally I’d like a line plot (so 2 lines, max and min ), but a bar plot is ok too. I just need an explanation as to how to implement this.