From 9d8342c888027c3ccdcb6d7dd20493883429b8c3 Mon Sep 17 00:00:00 2001 From: Brian Ward Date: Wed, 19 Apr 2023 10:42:57 -0400 Subject: [PATCH] Fix dead links --- src/cmdstan-guide/installation.Rmd | 2 +- src/cmdstan-guide/json_apdx.Rmd | 16 ++++++++-------- src/cmdstan-guide/log_prob_config.Rmd | 4 ++-- src/reference-manual/licenses.Rmd | 11 +++++------ src/reference-manual/types.Rmd | 4 ++-- src/stan-users-guide/for-bugs-users.Rmd | 2 +- src/stan-users-guide/user-functions.Rmd | 2 +- src/stan-users-guide/using-stanc.Rmd | 2 +- 8 files changed, 21 insertions(+), 22 deletions(-) diff --git a/src/cmdstan-guide/installation.Rmd b/src/cmdstan-guide/installation.Rmd index 956879e12..c6c170d6a 100644 --- a/src/cmdstan-guide/installation.Rmd +++ b/src/cmdstan-guide/installation.Rmd @@ -152,7 +152,7 @@ percentiles, effective number of samples, and $\hat{R}$ values. that the HMC sampler was unable to sample from the full posterior. CmdStan releases include pre-built binaries of the Stan language -compiler \url {https://github.com/stan-dev/stanc3}: +compiler (https://github.com/stan-dev/stanc3): `bin/linux-stanc`, `bin/mac-stanc` and `bin/windows-stanc`. The CmdStan makefile `build` task copies the appropriate binary to `bin/stanc`. For CmdStan diff --git a/src/cmdstan-guide/json_apdx.Rmd b/src/cmdstan-guide/json_apdx.Rmd index c2615c0fd..9cc649f5e 100644 --- a/src/cmdstan-guide/json_apdx.Rmd +++ b/src/cmdstan-guide/json_apdx.Rmd @@ -9,15 +9,15 @@ parameters are used to initialize the sampler and optimizer. You can create the JSON file yourself using the guidelines below, but a more convenient way to create a JSON file for use with CmdStan is to use the -[`write_stan_json()`](https://mc-stan.org/cmdstanr/reference/write_stan_json) +[`write_stan_json()`](https://mc-stan.org/cmdstanr/reference/write_stan_json) function provided by the CmdStanR interface. ## JSON syntax summary JSON is a data interchange notation, defined by an -\href{http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf}{ECMA -standard}. JSON data files must in Unicode. JSON data is a series of +[EMCA standard](http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf). +JSON data files must in Unicode. JSON data is a series of structural tokens, literal tokens, and values: - Structural tokens are the left and right curly bracket `{}`, left and right @@ -44,10 +44,10 @@ There is no distincition between integer and real numbers in the JSON format other than whether they have periods or scientific notation. -- The special floating point values for positive infinity, negative infinity, +- The special floating point values for positive infinity, negative infinity, and not-a-number can be represented in multiple ways. Positive infinity can be represented as the string `"Inf"`, the string `"Infinity"`, or the atom `Infinity`. -Negative infinity can be represented as the string `"-Inf"`, the string `"-Infinity"`, +Negative infinity can be represented as the string `"-Inf"`, the string `"-Infinity"`, or the atom `-Infinity`. Not-a-number can be represented as the string `"NaN"` or the atom `NaN`. These values may be mixed with other numerical types. @@ -82,15 +82,15 @@ example, the $2 \times 3$ matrix is represented in JSON as `[[1, 2.7, -9.8], [4.2, 1.8, -7.3]]`. - + - Complex matrices are also represented as arrays of their row -vectors. For example, the $2 \times 3$ complex matrix +vectors. For example, the $2 \times 3$ complex matrix \[ \begin{bmatrix} 1 + 2i & 3 - 4.2i & 13.1 + 2.7i \\ 3.1 & -5i & 0 \end{bmatrix} -\] +\] would be represented in JSON as ` [[[1, 2], [3, -4.2], [13.1, 2.7]], diff --git a/src/cmdstan-guide/log_prob_config.Rmd b/src/cmdstan-guide/log_prob_config.Rmd index 9bdb4c0bc..ec4b5e399 100644 --- a/src/cmdstan-guide/log_prob_config.Rmd +++ b/src/cmdstan-guide/log_prob_config.Rmd @@ -20,8 +20,8 @@ This method takes 3 arguments: - `constrained_params` - Input file of parameters values on the constrained scale. A single set of constrained parameters can be specified using -[JSON](json_apdx.html) or [Rdump](rdump_apdx.html) format. -Alternatively, the input file can be set of draws in [StanCSV](stan_csv_apdx.html) format. +[JSON](json.html) or [Rdump](rdump.html) format. +Alternatively, the input file can be set of draws in [StanCSV](stan_csv.html) format. - `unconstrained_params` - Input file (JSON or R dump) of parameter values diff --git a/src/reference-manual/licenses.Rmd b/src/reference-manual/licenses.Rmd index ca8e2b5c5..f2007f70c 100644 --- a/src/reference-manual/licenses.Rmd +++ b/src/reference-manual/licenses.Rmd @@ -17,7 +17,7 @@ run Stan. Stan is distributed under -* [BSD 3-clause license (BSD New)](http://www.opensource.org/licenses/BSD-3-Clause)} +* [BSD 3-clause license (BSD New)](http://www.opensource.org/licenses/BSD-3-Clause) The copyright holder of each contribution is the developer or his or her assignee.^[Universities or companies often own the copyright of computer programs developed by their employees.] @@ -30,7 +30,7 @@ programs, the parser, and various numerical libraries for special functions, probability functions, and random number generators. Boost is distributed under the -* [Boost Software License version 1.0](http://www.opensource.org/licenses/BSL-1.0) +* [Boost Software License version 1.0](https://opensource.org/license/bsl1-0-html/) The copyright for each Boost package is held by its developers or their assignees. @@ -39,7 +39,7 @@ their assignees. ## Eigen license Stan uses the Eigen library for matrix arithmetic and linear algebra. -Eigen is distributed under the +Eigen is distributed under the * [Mozilla Public License, version 2](http://opensource.org/licenses/mpl-2.0) @@ -52,7 +52,7 @@ assignees. Stan uses the SUNDIALS package for solving differential equations. SUNDIALS is distributed under the -* [BSD 3-clause license (BSD New)](http://www.opensource.org/licenses/BSD-3-Clause)} +* [BSD 3-clause license (BSD New)](http://www.opensource.org/licenses/BSD-3-Clause) The copyright of SUNDIALS is owned by Lawrence Livermore National Security Lab. @@ -63,7 +63,6 @@ Security Lab. Stan uses Google Test for unit testing; it is not required to compile or execute models. Google Test is distributed under the -* [BSD 3-clause license (BSD New)](http://www.opensource.org/licenses/BSD-3-Clause)} +* [BSD 3-clause license (BSD New)](http://www.opensource.org/licenses/BSD-3-Clause) The copyright of Google Test is owned by Google, Inc. - diff --git a/src/reference-manual/types.Rmd b/src/reference-manual/types.Rmd index d10df44ca..a664bc9e5 100644 --- a/src/reference-manual/types.Rmd +++ b/src/reference-manual/types.Rmd @@ -43,7 +43,7 @@ part of their behavior. Stan provides two primitive data types, `real` for continuous values and `int` for integer values. These are both considered scalar -types. +types. ### Complex types {-} @@ -1554,7 +1554,7 @@ specified by using commas, e.g. `array[ , ]` is a 2-D array. For more on how function arguments and return types are declared, consult the [User's Guide chapter on -functions](https://mc-stan.org/docs/stan-users-guide/basic-functions-section.html#type-declarations-for-functions). +functions](https://mc-stan.org/docs/stan-users-guide/basic-functions.html#type-declarations-for-functions). ## Compound variable declaration and definition diff --git a/src/stan-users-guide/for-bugs-users.Rmd b/src/stan-users-guide/for-bugs-users.Rmd index 9ef19c3c8..783e20723 100644 --- a/src/stan-users-guide/for-bugs-users.Rmd +++ b/src/stan-users-guide/for-bugs-users.Rmd @@ -18,7 +18,7 @@ model is translated to templated C++ and then to a platform-specific executable. Stan, unlike BUGS, allows the user to directly program in C++, but we do not describe how to do this in this Stan manual (see the getting started with C++ section of -\url{https://mc-stan.org} for more information on using Stan directly +https://mc-stan.org for more information on using Stan directly from C++). ### BUGS performs MCMC updating one scalar parameter at a time, Stan uses HMC which moves in the entire space of all the parameters at each step {-} diff --git a/src/stan-users-guide/user-functions.Rmd b/src/stan-users-guide/user-functions.Rmd index d454ae8e3..96dee04ab 100644 --- a/src/stan-users-guide/user-functions.Rmd +++ b/src/stan-users-guide/user-functions.Rmd @@ -700,7 +700,7 @@ back. #### Truncating below {-} -For example, the following code generates a $\textsf{Weibull}(\alpha, \sigma)$ variate truncated below at a time $t$,^[The original code and impetus for including this in the manual came from the Stan forums post \url{http://discourse.mc-stan.org/t/rng-for-truncated-distributions/3122/7}; by user `lcomm`, who also explained truncation above and below.] +For example, the following code generates a $\textsf{Weibull}(\alpha, \sigma)$ variate truncated below at a time $t$,^[The original code and impetus for including this in the manual came from the [Stan forums post](http://discourse.mc-stan.org/t/rng-for-truncated-distributions/3122/7); by user `lcomm`, who also explained truncation above and below.] ```stan real weibull_lb_rng(real alpha, real sigma, real t) { diff --git a/src/stan-users-guide/using-stanc.Rmd b/src/stan-users-guide/using-stanc.Rmd index 0f00c8285..ef1e13cb3 100644 --- a/src/stan-users-guide/using-stanc.Rmd +++ b/src/stan-users-guide/using-stanc.Rmd @@ -675,7 +675,7 @@ In addition to compiling Stan programs, stanc3 features several [flags](#stanc-a which can be used to format Stan programs and update them to the most recent Stan syntax by removing any [deprecation -features](https://mc-stan.org/docs/reference-manual/deprecated-features-appendix.html) +features](https://mc-stan.org/docs/reference-manual/deprecated-features.html) which can be automatically replaced. These flags work for both `.stan` model files and `.stanfunctions` function