set_context stores a simple context about the experiment. The context is printed when the return object is printed as well as exported in the title sheet (see export_design()). If the context already exists then it will be overwritten.

You can use sort_context to reorder named context alphabetically. If you don't want to see the context printed out each time, use suppress_context to muffle the context and express_context to turn on the context print out. Use switch_context to turn on print out of context if it was switched off, or turn off print out if it was switched on.

set_context(.edibble, ...)

  descending = FALSE,
  method = c("auto", "shell", "radix")





An edibble design (EdibbleDesign), an edibble data frame (edbl_table) or an object that contains the edibble data frame in the attribute design.


Strings of contexts or notes for the experiment. The context maybe named. If you context it is wrong, consider writing the context in an external file then write the reference to the file in context instead. Input strings support inline markup that use glue braces as well cli markup formatter. The formatting is evaluated and stored in EdibbleDesign.


Whether to sort it in ascending or descending alphabetical order.


the method to use for ordering. See base::order() for explanation.


Same as original except EdibbleDesign updated with context.

See also


files <- c("details.txt", "about.docx") start_design("COVID-19") %>% set_context(question = "Does {.field Pfizer vaccine} work?", where = "Tested in {.emph lab}", contact = "{.strong Jane Doe} ({.email}) for domain knowledge", "Context do not have to be named", "The function {.fn designRandomise} from {.pkg dae} randomises allocation of treatments", "Other detailed information in {.file {files}}", "Check more details at {.url}")
#> Does Pfizer vaccine work?
#> Tested in lab
#> Jane Doe ( for domain knowledge
#> Context do not have to be named
#> The function `designRandomise()` from dae randomises allocation of treatments
#> Error in eval(expr, envir = list(`?` = function(...) stop()), enclos = envir): object 'files' not found