If a have a data frame that has columns names of:
x y1 y2 y3
and I want a line plot with 3 different colored lines, y1, y2 and y3 plotted against x, how do I do this with ggplot and how do I add a legend that has the column names with their corresponding colors?
dput(your_df). Consider putting the data into long format usingtidyr::pivot_longer()