Skip to content

Commit

Permalink
cran updates
Browse files Browse the repository at this point in the history
  • Loading branch information
jmsigner committed Sep 19, 2019
1 parent 2e68914 commit 511c5fe
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
15 changes: 11 additions & 4 deletions R/eda_sampling_rate.R
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,16 @@ summarize_sampling_rate_many <- function(x, ...) {
}

#' @rdname summarize_sampling_rate
#' @param cols `[character(>= 1)]` \cr Indicating columns to be used as grouping variables.
#' @export
summarize_sampling_rate_many.track_xyt <- function(x, ...) {
ids <- rlang::enquos(...)
x %>% group_by(!!!ids) %>% nest() %>% mutate(ts = map(data, summarize_sampling_rate)) %>%
select(!!!ids, ts) %>% unnest()
#' @examples
#' data(amt_fisher)
#' # Add the month
#' amt_fisher %>% mutate(yday = lubridate::yday(t_)) %>%
#' summarize_sampling_rate_many(c("id", "yday"))
#'
summarize_sampling_rate_many.track_xyt <- function(x, cols, ...) {
##ids <- rlang::enquos(...)
x %>% nest(data = -{{ cols }}) %>% mutate(ts = map(data, summarize_sampling_rate)) %>%
select(cols, ts) %>% unnest(cols = ts)
}
9 changes: 8 additions & 1 deletion man/summarize_sampling_rate.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 511c5fe

Please sign in to comment.