diff --git a/reflections/20240827/Rplots.pdf b/reflections/20240827/Rplots.pdf new file mode 100644 index 0000000..93fbac9 Binary files /dev/null and b/reflections/20240827/Rplots.pdf differ diff --git a/reflections/20240827/analyse.R b/reflections/20240827/analyse.R new file mode 100755 index 0000000..cc1c129 --- /dev/null +++ b/reflections/20240827/analyse.R @@ -0,0 +1,27 @@ +#!/bin/env Rscript + +t <- readr::read_csv("counts.csv") +t$total <- t$n_cam_on + t$n_cam_off + +ggplot2::ggplot(t, ggplot2::aes(x = time, y = total)) + + ggplot2::geom_area(fill = "grey") + + ggplot2::geom_line(ggplot2::aes(x = time, y = n_cam_on), color = "green") + + ggplot2::geom_point(ggplot2::aes(x = time, y = n_cam_on), color = "green") + + ggplot2::geom_line(ggplot2::aes(x = time, y = n_cam_off), color = "red") + + ggplot2::geom_point(ggplot2::aes(x = time, y = n_cam_off), color = "red") + + ggplot2::scale_x_time() + + ggplot2::labs( + caption = paste0( + "Green: camera on. Red: camera off. Shade: total.\n" + ) + ) + + ggplot2::theme( + axis.text.x = ggplot2::element_text( + angle = 90, + vjust = 0.5, + hjust = 1 + ) + ) + +# ggplot2::scale_x_time(labels = "%H:%M") + + \ No newline at end of file diff --git a/reflections/20240827/counts.csv b/reflections/20240827/counts.csv new file mode 100644 index 0000000..19ad8bd --- /dev/null +++ b/reflections/20240827/counts.csv @@ -0,0 +1,13 @@ +time,n_cam_on,n_cam_off +8:58,2,2 +9:29,15,1 +9:57,14,2 +10:31,15,1 +11:48,16,1 +13:08,15,0 +13:48,15,0 +14:23,14,1 +14:48,15,0 +15:18,13,2 + + diff --git a/reflections/20240827/counts.png b/reflections/20240827/counts.png new file mode 100644 index 0000000..f1d089e Binary files /dev/null and b/reflections/20240827/counts.png differ diff --git a/reflections/20240827/other_course_20240822_day_1.png b/reflections/20240827/other_course_20240822_day_1.png new file mode 100644 index 0000000..852045b Binary files /dev/null and b/reflections/20240827/other_course_20240822_day_1.png differ diff --git a/reflections/20240827/other_course_20240823_day_2.png b/reflections/20240827/other_course_20240823_day_2.png new file mode 100644 index 0000000..f50474f Binary files /dev/null and b/reflections/20240827/other_course_20240823_day_2.png differ