Find all specimens associated with the provided specimen entries. Useful for exporting.

find_all_specimens(
  specimen_entries,
  date_format = getOption("sampledblib.dateformat", "%d/%m/%Y"),
  as_data_frame = TRUE
)

Arguments

specimen_entries

list of specimen entries to search for

date_format

optional date formatting string for output

as_data_frame

logical indicating whether to return as data.frame. Default is TRUE.

Value

list or data.frame of specimens and their locations

Details

Specimen entries are named lists structured as:

specimen_entry -> {
  'uid': Unique study subject ID,
  'short_code': Unique study short code,
  'specimen_type': String descriptor of specimen, must be registered,
  'collection_date': Optional date of collection,
}

specimen entries should be created from a CSV