I want to plot all columns from a data table. My data table has 100 columns and 5 rows. Each row is a date and each column is a different person. How could I do it? I've tried the following code, but it only plots the last register:
plot1 <- ggplot(data, aes(x = date))
for (i in 1:100){
plot1 <- plot1 + geom_line(aes(y = data[ , i]))}
Hi @ignareeva,
Did martin's answer solve your problem? If so, it would be great if you could mark their answer as the solution.
If you're still stuck, I'd be happy to help, especially if you can provide a minimal reproducible example of your data (some info on how to do that is here).