| xlsform_outline | R Documentation |
Parses an XLSForm and returns one row for each item that would appear on the paper form: sections, questions, notes and the end of repeat groups. It shows the question numbers, the answer type, the number of choices, and the skip logic and constraints in plain language, so a form can be checked before it is converted.
xlsform_outline(xlsform, lang = NULL, ...)
xlsform |
Path to an XLSForm ( |
lang |
Language to use: a code ( |
... |
Further options: |
A data.frame with one row per block and columns row (Excel row of
the form), serial (question number, NA when unnumbered), depth
(number of enclosing groups), block ("section", "section_end",
"note" or "question"), kind (the question kind, for example
"select_one", or "begin_group", "begin_repeat", "end_repeat",
"note"), name, label, required, n_choices (all choices of a
select or rank question, not counting an "other" row), relevant_text,
constraint_text (the constraint message when the form has one, else the
humanized expression) and layout (for select and rank questions:
"list", "columns" or "code_box", from the number of choices and
max_choices; NA otherwise). A label may contain line breaks (\n).
path <- system.file("extdata", "minimal", "minimal.xlsx",
package = "convertxlsform")
out <- xlsform_outline(path)
out[, c("serial", "block", "kind", "name", "relevant_text")]
# A multilingual form: another language, with flat question numbers
path_ml <- system.file("extdata", "multilang", "multilang.xlsx",
package = "convertxlsform")
out <- xlsform_outline(path_ml, lang = "bn", nested_serial_numbers = FALSE)
head(out[, c("serial", "name")], 5)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.