Posts by rdornas • 111 points
2 posts
-
0
votes3
answers100
viewsA: How to generate graphics from a file using a loop in R?
It’s been a while, but I’ll try to add one more answer using the functions tidyr::nest and purrr::map. Generally speaking, it is a more complete possibility in terms of tidyverse. All generated…
-
1
votes1
answer60
viewsQ: How to create numerical samples based on multiple conditions on multiple vectors?
Given the following data frame: df <- tibble::tribble( ~pass_id, ~km_ini, ~km_fin, 1L, 0.89, 2.39, 2L, 1.53, 3.03, 3L, 21.9, 23.4, 4L, 23.4, 24.9, 5L, 24, 25.5, 6L, 25.9, 27.4, 7L, 36.7, 38.2,…