Skip to content

Commit

Permalink
Update tidyselect data-expressions
Browse files Browse the repository at this point in the history
  • Loading branch information
njahn82 committed Aug 21, 2023
1 parent a66345b commit f761359
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions R/annotations_by_id.R
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,13 @@ epmc_annotations_by_id_ <- function(ids = NULL, .pb = NULL) {
out <- tibble::tibble(
source = req[["source"]],
ext_id = req[["extId"]],
pmcid = dplyr::if_else(
pmcid = ifelse(
is.null(req[["pmcid"]]), NA_character_, req[["pmcid"]]
),
annotations = req[["annotations"]]
)
tidyr::unnest(tidyr::unnest(out, .data$annotations),
.data$tags)
tidyr::unnest(tidyr::unnest(out, "annotations"),
"tags")
} else {
NULL
}
Expand Down
2 changes: 1 addition & 1 deletion R/epmc_details.r
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ parse_aut <- function(res) {
out <- tibble::tibble()
}
if("authorAffiliationDetailsList.authorAffiliation" %in% colnames(out))
out <- tidyr::unnest(out, cols = c(.data$authorAffiliationDetailsList.authorAffiliation))
out <- tidyr::unnest(out, cols = c("authorAffiliationDetailsList.authorAffiliation"))
return(out)
}

Expand Down

0 comments on commit f761359

Please sign in to comment.