Skip to contents

For a detailed explanation of these tokens see the vignette Create and Customize the index Template.

Usage

lookup_tokens(tokens, scheme, author = "")

Arguments

tokens

a character vector containing tokens. These can be enclosed in %%TOKEN%% or not.

scheme

a dmdSchemeSet object

author

the author of the index document

Value

a list of the length of the input vector tokens

containing the objects returned by the tokens. Null if the tokens contains invalid values.

Examples

lookup_tokens(
  tokens = c(
      "%%Treatments.*.2%%",
     "%%Experiment.*.*%%",
     "Measurement.method.3"
   ),
  scheme = dmdScheme_example(),
)
#> $`%%Treatments.*.2%%`
#>     treatmentID treatmentLevelHeight comment
#> 2 Lid_treatment                Tight    <NA>
#> 
#> $`%%Experiment.*.*%%`
#>        name temperature        light humidity      incubator
#> 1 ASR-expt1          20 semi-ambient  ambient not given here
#>                            container microcosmVolume mediaType
#> 1 Duran type bottle, red lids, 250ml             100       PPM
#>   mediaConcentration cultureConditions      comunityType
#> 1               0.55             dirty initially unknown
#>                                                           mediaAdditions
#> 1 Wheat seeds added on specific dates, see file wheat_seed_additions.csv
#>   duration comment
#> 1      100    <NA>
#> 
#> $Measurement.method.3
#> [1] "nose"
#>