Learn R Programming

wikkitidy (version 0.1.14)

xtools_page: Access page-level statistics from the XTools Page API endpoint

Description

get_xtools_page_info() returns basic statistics about articles' history and quality, including their total edits, creation date, and assessment value (good, featured etc.)

get_xtools_page_prose() returns statistics about the word counts and referencing of articles

get_xtools_page_links() returns the number of ingoing and outgoing links to articles, including redirects

get_xtools_page_top_editors() returns the list of top editors for articles, with optional filters by date range and non-bot status

get_xtools_page_assessment() returns more detailed statistics about articles' assessment status and Wikiproject importance levels

Usage

get_xtools_page_info(title, language = "en", failure_mode = "error")

get_xtools_page_prose( title, language = "en", failure_mode = c("error", "quiet") )

get_xtools_page_links( title, language = "en", failure_mode = c("error", "quiet") )

get_xtools_page_top_editors( title, start = NULL, end = NULL, limit = 1000, nobots = FALSE, language = "en", failure_mode = c("error", "quiet") )

get_xtools_page_assessment( title, classonly = FALSE, language = "en", failure_mode = c("error", "quiet") )

Value

A list or tbl of results, the same length as title. NB: The results for get_xtools_page_assessment are still not parsed properly.

Arguments

title

Character vector of page titles

language

Language code for the version of Wikipedia to query

failure_mode

What to do if no data is found. See get_rest_resource()

start

A character vector or date object (optional): the start date for calculating top editors

end

A character vector or date object (optional): the end date for calculating top editors

limit

An integer: the maximum number of top editors to return

nobots

TRUE or FALSE: if TRUE, bots are excluded from the top editor calculation

classonly

TRUE or FALSE: if TRUE, only return the article's assessment status, without Wikiproject information

Examples

Run this code
# Get basic statistics about Erich Auerbach on German Wikipedia
auerbach <- get_xtools_page_info("Erich Auerbach", language = "de", failure_mode = "quiet")
auerbach

Run the code above in your browser using DataLab