The preregr
vignettes are themselves RMarkdown files.
Therefore, the human-readable (pre-)registrations shown there as an
example also caused the corresponding JSON to be embedded in those
vignettes.
This command imports this information from the preregr
Pkgdown website:
<-
importedExample ::import_from_html("https://r-packages.gitlab.io/preregr/articles/specifying_prereg_content.html"); preregr
We can then show the result:
importedExample;#>
#> ── (Pre)registration specification ─────────────────────────────────────────────
#> ℹ Form: Inclusive Systematic Review Registration Form
#> ℹ 65 fields (3 completed, 62 empty)
Or knit it into this vignette (which will then again also embed it as JSON, which can be imported again, etc):
::prereg_knit_item_content(
preregr
importedExample,section="metadata"
);
It is also possible to initialize a new preregistration, using the form that was saved along with the preregistered content:
<-
freshPrereg ::prereg_initialize(
preregr
importedExample );
This yields an empty preregistration specification:
freshPrereg;
── (Pre)registration specification ─────────────────────────────────────────────: Inclusive Systematic Review Registration Form
ℹ Form65 fields (0 completed, 65 empty) ℹ
This way, it’s easy to initialize a preregistration based on the form used by somebody else.