Hao Ye 2019-09-04
Load the data.
library(rcrossref)
library(tidyverse)
## ── Attaching packages ───────────────────────────────────────────── tidyverse 1.2.1 ──
## ✔ ggplot2 3.2.1 ✔ purrr 0.3.2
## ✔ tibble 2.1.3 ✔ dplyr 0.8.3
## ✔ tidyr 0.8.3 ✔ stringr 1.4.0
## ✔ readr 1.3.1 ✔ forcats 0.4.0
## ── Conflicts ──────────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag() masks stats::lag()
crossref_query <- readRDS("test_data.RDS")
crossref_data <- crossref_query$data
Extract the citation links from the crossref results:
source("build_network.R")
links <- extract_citation_links(crossref_data)
library(ggraph)
net <- igraph::graph_from_data_frame(links)
## Warning in igraph::graph_from_data_frame(links): In `d' `NA' elements were
## replaced with string "NA"
ggraph(net) +
geom_node_point() +
geom_edge_link() +
theme_bw()
## Using `nicely` as default layout