manual orcid doi pull

This commit is contained in:
Andreas Gammelgaard Damsbo 2023-05-08 10:52:31 +02:00
parent cb352719be
commit 60dc4de757

35
cv.Rmd
View File

@ -60,21 +60,24 @@ tribble(
library(dplyr) library(dplyr)
library(rorcid) library(rorcid)
# works <- rorcid::orcid_works(orc_id)[[1]] if (!file.exists("publications.bib")) {
# works <- rorcid::orcid_works(orc_id)[[1]]
# edu <- do.call("rbind",
# rorcid::orcid_educations(orc_id)[[1]] dois <-
# ) Reduce(c, do.call(
cbind,
# orc_id <- "0000-0002-7559-1154" lapply(works$works$`external-ids.external-id`, function(a) {
# pubs <- orcid_citations(orcid = orc_id, put_code=NULL) if ("doi" %in% c(a[[1]])) {
# s <- do.call(cbind, a)
# writeLines(pubs$citation, "publications.bib") s[, "external-id-normalized.value"][s[, "external-id-type"] == "doi"]
# bibliography_entries("pubs.bib") %>% }
# arrange(desc(author$family), issued) })
)) |> na.omit() |> unique()
# rorcid::check_dois(dois)
RefManageR::GetBibEntryWithDOI(dois) |> rbibutils::writeBib("publications.bib")
}
bibliography_entries("pubs.bib") %>% bibliography_entries("publications.bib") %>%
arrange(desc(issued)) arrange(desc(author$family), issued)
## Currently not working; I think it is due to error in DOI lookup with latest article.
``` ```