This might sound simple or complex, but how do I create a legend like this for my plot(I just need 1 legend for the whole group)
Legend
4=Standing
3=Stepping
2=Cycling
1=Sitting
this is the code that I have so far:
graph_pre <- mutate(graph_pre, day = lubridate::day(Date))
ggplot(graph_pre, aes(x = Time, y = Posture))+
geom_point()+
facet_wrap(~day, scales = "free_x")
And here is the output