Learn R Programming

RefManageR (version 1.4.0)

as.data.frame.BibEntry: Coerce to a Data Frame

Description

Coerces a BibEntry object to a data.frame, with each row of the data frame being a field present in at least one entry in the BibEntry object being coerced.

Usage

# S3 method for BibEntry
as.data.frame(x, row.names = NULL, optional = FALSE, ...)

Value

a data.frame object with row names giving the keys, and first column giving entry type.

Arguments

x

- a BibEntry object

row.names

- ignored

optional

- ignored

...

- ignored

See Also

BibEntry, as.BibEntry

Examples

Run this code
bib <- list(c(bibtype = "article", key = "mclean2014a", title = "My New Article",
  author = "Mathew W. McLean", journaltitle = "The Journal", date = "2014-01"),
  c(bibtype = "article", key = "mclean2014b", volume = 10, title = "My Newer Article",
  author = "Mathew W. McLean", journaltitle = "The Journal", date = "2014-02"))
bib <- as.BibEntry(bib)
as.data.frame(bib)

Run the code above in your browser using DataLab