Learn R Programming

gcite (version 0.11.0)

gcite_cite_over_time: Parse Google Citations Over Time

Description

Parses a google citations over time from the main Citation page

Usage

gcite_cite_over_time(doc, ...)

# S3 method for xml_node gcite_cite_over_time(doc, ...)

# S3 method for xml_document gcite_cite_over_time(doc, ...)

# S3 method for character gcite_cite_over_time(doc, ...)

# S3 method for default gcite_cite_over_time(doc, ...)

Value

A matrix of citations

Arguments

doc

A xml_document or the url for the main page

...

arguments passed to GET

Examples

Run this code
library(httr)
library(rvest) 
url = "https://scholar.google.com/citations?user=T9eqZgMAAAAJ"
url = gcite_url(url = url, pagesize = 10, cstart = 0) 
if (!is_travis() & !is_cran()) {
#' ind = gcite_cite_over_time(url)
doc = content(httr::GET(url))
ind = gcite_cite_over_time(doc)
ind_nodes = rvest::html_nodes(doc, ".gsc_md_hist_b")
ind = gcite_cite_over_time(ind_nodes)
}

Run the code above in your browser using DataLab