Skip to content

Commit 02b074d

Browse files
committed
update doc based on reviewer feedback
1 parent b982c34 commit 02b074d

2 files changed

Lines changed: 16 additions & 2 deletions

File tree

R/model.R

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -945,8 +945,15 @@ CmdStanModel$set("public", name = "check_syntax", value = check_syntax)
945945
#' x ~ std_normal();
946946
#' }
947947
#' ")
948+
#'
949+
#' # set compile=FALSE then call format to fix old syntax
948950
#' mod <- cmdstan_model(file, compile = FALSE)
949-
#' mod$format(canonicalize = TRUE)
951+
#' mod$format(canonicalize = list("deprecations"))
952+
#'
953+
#' # overwrite the original file instead of just printing it
954+
#' mod$format(canonicalize = list("deprecations"), overwrite_file = TRUE)
955+
#' mod$compile()
956+
#'
950957
#'
951958
#' # Example of removing unnecessary whitespace
952959
#' file <- write_stan_file("

man/model-method-format.Rd

Lines changed: 8 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)