metadata_utils: Access pieces of metadata from a 'pdb' object

pdb_citationsR Documentation

Access pieces of metadata from a pdb object

Description

These functions access pieces of specific pieces metadata from the Metadata table of a pdb object. The exception is pdb_report, which automatically generates a report with summary statistics and citation information for the pdb object.

Usage

pdb_citations(pdb, ipm_id = NULL)

pdb_species_accepted(pdb, ipm_id = NULL)

pdb_species_author(pdb, ipm_id = NULL)

pdb_genus(pdb, ipm_id = NULL)

pdb_family(pdb, ipm_id = NULL)

pdb_order(pdb, ipm_id = NULL)

pdb_class(pdb, ipm_id = NULL)

pdb_phylum(pdb, ipm_id = NULL)

pdb_kingdom(pdb, ipm_id = NULL)

pdb_org_type(pdb, ipm_id = NULL)

pdb_dicot_monocot(pdb, ipm_id = NULL)

pdb_angio_gymon(pdb, ipm_id = NULL)

pdb_authors(pdb, ipm_id = NULL)

pdb_journal(pdb, ipm_id = NULL)

pdb_pub_year(pdb, ipm_id = NULL)

pdb_doi(pdb, ipm_id = NULL)

pdb_comments(pdb, ipm_id = NULL)

pdb_appendix_link(pdb, ipm_id = NULL)

pdb_duration(pdb, ipm_id = NULL)

pdb_start_year(pdb, ipm_id = NULL)

pdb_start_month(pdb, ipm_id = NULL)

pdb_end_year(pdb, ipm_id = NULL)

pdb_end_month(pdb, ipm_id = NULL)

pdb_periodicity(pdb, ipm_id = NULL)

pdb_population_name(pdb, ipm_id = NULL)

pdb_number_populations(pdb, ipm_id = NULL)

pdb_lat(pdb, ipm_id = NULL)

pdb_lon(pdb, ipm_id = NULL)

pdb_altitude(pdb, ipm_id = NULL)

pdb_country(pdb, ipm_id = NULL)

pdb_continent(pdb, ipm_id = NULL)

pdb_ecoregion(pdb, ipm_id = NULL)

pdb_studied_sex(pdb, ipm_id = NULL)

pdb_eviction_used(pdb, ipm_id = NULL)

pdb_evict_type(pdb, ipm_id = NULL)

pdb_treatment(pdb, ipm_id = NULL)

pdb_has_time_lag(pdb, ipm_id = NULL)

pdb_has_age(pdb, ipm_id = NULL)

pdb_report(
  pdb,
  title = "",
  keep_rmd = TRUE,
  rmd_dest = getwd(),
  output_format = "html",
  render_output = TRUE,
  map = TRUE,
  translate_eqs = FALSE,
  block_eqs = FALSE,
  long_eq_length = 65
)

Arguments

pdb

A Padrino Database object.

ipm_id

The ID of the model. The default (NULL) returns all values in the pdb object.

title

The title for the created report.

keep_rmd

Keep the un-rendered Rmd file? Useful for manual editing.

rmd_dest

The folder to save the Rmd file at if keep_rmd = TRUE. The default is getwd().

output_format

The output format to create. Options are "html", "pdf", "word", "odt", "rtf", or "md".

render_output

A logical - should the document be rendered for inspection?

map

Create a map of studies included in the pdb object?

translate_eqs

A logical - should the mathematical equations of the IPM(s) also be included in the report? These are translated from R to Latex by make_ipm_report_body. Currently, this is only available for IPMs that do not have parameter set indexed terms.

block_eqs

If report_eqs = TRUE, should equations be reported in block format or as inline equations? This main difference for "pdf" formats is that equation numbering is done with tag{}. For non-"pdf" formats, the difference is that equations are centered. Numbering may yield strange results for non-"pdf" formats.

long_eq_length

For longer equations, make_ipm_report tries to wrap these into multiple lines using \\. This parameter controls the number of characters per line. Default is 65. Ignored when block_eqs = FALSE.

Value

A named vector of the metadata. The names correspond to ipm_idss. For pdb_report, the file path to the rendered output, or to the .rmd file when render_output = FALSE.


Rpadrino documentation built on April 30, 2022, 1:05 a.m.