pmc_table: Convert table nodes to tibbles

Description Usage Arguments Value Note Author(s) Examples

View source: R/pmc_table.R

Description

Convert PubMed Central table nodes into a list of tibbles

Usage

1
pmc_table(doc)

Arguments

doc

xml_document from PubMed Central

Value

a list of tibbles

Note

Saves the caption and footnotes as attributes and collapses multiline headers, expands all rowspan and colspan attributes and adds subheadings to column one.

Author(s)

Chris Stubben

Examples

1
2
3
4
5
6
7
8
# doc <- pmc_xml("PMC2231364")
doc <- xml2::read_xml(system.file("extdata/PMC2231364.xml",
  package = "tidypmc"
))
x <- pmc_table(doc)
sapply(x, dim)
x
attributes(x[[1]])

tidypmc documentation built on Aug. 1, 2019, 5:05 p.m.