This function takes a bibentry and converts it to a data frame.

bibentry_to_df(
  bibentry,
  authorCollapseFunc = metabefor::vecTxt,
  authorCollapseArgs = list(delimiter = " and ", lastDelimiter = NULL)
)

Arguments

bibentry

The bibentry (or bibentries)

authorCollapseFunc

The function to use to collapse the vector of author names into one value.

authorCollapseArgs

Argyments to pass to authorCollapseFunc().

Value

A data frame

Examples

### Use the base R bibentry
metabefor::bibentry_to_df(citation());
#>                                                     title     author
#> 1 R: A Language and Environment for Statistical Computing NULL, NULL
#>                             organization         address year
#> 1 R Foundation for Statistical Computing Vienna, Austria 2024
#>                          url bibtype
#> 1 https://www.R-project.org/  Manual