gcite_papers: Parse Google Citation Index

Description Usage Arguments Value Examples

View source: R/gcite_papers.R

Description

Parses a google citation indices (h-index, etc.) from main page

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
gcite_papers(doc, ...)

## S3 method for class 'xml_nodeset'
gcite_papers(doc, ...)

## S3 method for class 'xml_document'
gcite_papers(doc, ...)

## S3 method for class 'character'
gcite_papers(doc, ...)

## Default S3 method:
gcite_papers(doc, ...)

Arguments

doc

A xml_document or the url for the main page

...

Additional arguments passed to GET if doc is a URL

Value

A matrix of indices

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
if (!is_travis()) {
library(httr)
library(rvest) 
url = "https://scholar.google.com/citations?user=T9eqZgMAAAAJ"
url = gcite_url(url = url, pagesize = 10, cstart = 0) 
ind = gcite_papers(url)
doc = content(httr::GET(url))
ind = gcite_papers(doc)
ind_nodes = rvest::html_nodes(doc, "#gsc_a_b")
ind = gcite_papers(ind_nodes)
}

muschellij2/gcite documentation built on Feb. 6, 2018, 7:45 a.m.