Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

next manual, 2.18(++) #15

Closed
bob-carpenter opened this issue Jun 16, 2018 · 36 comments
Closed

next manual, 2.18(++) #15

bob-carpenter opened this issue Jun 16, 2018 · 36 comments
Assignees
Milestone

Comments

@bob-carpenter
Copy link
Contributor

Summary:

This is the place to record typos and brainos or suggestions for the manual. Most of the changes for 2.18 have already been merged, but we might make another round of updates before the 2.18 release. Otherwise, these will go in the release after that.

Current Version:

v2.17.1

@bob-carpenter bob-carpenter self-assigned this Jun 16, 2018
@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Jun 16, 2018

  • In thematrix_exp_multiply function doc, the expanded form should read \farg{t} * \farg{A}.

@jrnold
Copy link

jrnold commented Jul 3, 2018

  • Figure 23.1: Update note: "cholesky_factor_cov[K] ... are only assignable to matrices of dimensions matrix[K, K]. Update to account for generalization of choleskey_factor_cov to rectangular matrices. Perhaps update the cholesky_factor_cov row in the table. I searched for choelesky_factor_cov in the manual and didn't see any other cases in which it was stated that the matrix must be square for this type.

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Jul 3, 2018 via email

@jrnold
Copy link

jrnold commented Jul 5, 2018

Okay, I read it as still implying that cholesky_factor_cov itself has to be square; and the table itself doesn't have any mention of a non-square cholesky _factor_cov.

@ihincks
Copy link

ihincks commented Jul 11, 2018

  • In the subsection “Correlation Matrix Inverse Transform”: It reads that tanh maps into (0,1), but I think it should read (-1,1).

@bob-carpenter
Copy link
Contributor Author

Thanks, @ihincks. I'll fix that for 2.19, which should be out soon. 2.18 should be released in a few days, then we are targeting a mid-August release of 2.19.

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Jul 19, 2018

  • Remove the doc for abs because it's not vectorized (or vectorize it, but that's not a doc issue).

This came up with a post of @andrewgelman's on the forums

@bob-carpenter
Copy link
Contributor Author

  • explain why hierarchical models don't have MLEs other than when given zero-avoiding priors

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Jul 20, 2018

  • Qualify the statement "The Stan interfaces provide a mechanism for specifying a sequence of system paths in which to search for include files." to say "may provide".

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Jul 20, 2018

From a forum question of aornugent's

The output of each mapped function is concatenated to produce the output of map_rect.

Will this be concatenated in the same order as the sharded input data, or by whichever worker terminates first?

  • clarify that it's the order of the inputs

@jjramsey
Copy link

jjramsey commented Aug 8, 2018

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Aug 9, 2018

Thanks, @jjramsey --- I'll fix.

@jjramsey
Copy link

jjramsey commented Aug 16, 2018

  • There are some Markdown errors in the new reference manual. On page 28, after the heading "Array index style" is the text "{#array-index-style.footnote}". On page 131, instead of "Variable declarations and compound definitions" appearing in a header font, it just appears as the text "### Variable declarations and compound definitions {-}".

@jjramsey
Copy link

jjramsey commented Aug 20, 2018

  • There's a very minor issue with the users' guide PDF. In the section "Priors for length-scale", it reads "In this case, an inverse gamma, inv_gamma_lpdf in StanâAZs language, will work well", where the part that reads "StanâAZs language" is a bit garbled. It looks like the problem is that in the LaTeX source file examples.tex, the apostrophe in "Stan's" is represented by a Unicode "RIGHT SINGLE QUOTATION MARK" (code point U+2019) instead of an ASCII apostrophe.

@bob-carpenter
Copy link
Contributor Author

Thanks, @jjramsey. That'll be easy to fix. I should do a general search for non-ASCII characters.

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Aug 23, 2018

I'm not sure what the rest of the sentence is supposed to be, but the suspense is killing me ;-)

FYI:

https://github.com/stan-dev/stan/blob/01a09e735e2d0f880ab9219d469afce18d1b1934/src/docs/users-guide/examples.tex#L3342

PS. I tried instead to follow this link from the contributing guidelines, but it shows zero such open issues:

https://github.com/stan-dev/stan/issues?utf8=%E2%9C%93&q=is%3Aopen%20label%3ABug%20%22next%20manual%22%20label%3ADocumentation

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Sep 6, 2018

  • Add Ben's suggestion for truncated RNGs:

https://discourse.mc-stan.org/t/rng-for-truncated-distributions/3122/7?u=bgoodri

We could potentially generalize using the algebraic solver to compute general inverse CDFs, but I haven't tried it. There's more advice on doubly truncated things from @nschiett in:

stan-dev/math#214 (comment)

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Sep 19, 2018

From @avehtari on stan-dev/stan#2639:

The reference manual reference-manual-2.18.0.pdf downloaded from
https://github.com/stan-dev/stan/releases/download/v2.18.0/reference-manual-2.18.0.pdf

  • is missing some text at the end of page 153
  • Figure 14.1 is on page 153, but the caption is on page 152

(these are probably due switch to bookdown, but I don't know how to fix these)

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Sep 20, 2018

  • create a map_rect example that has different sizes for x and y.

  • write a simple version that groups by single element and deals with one output and three predictors

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Sep 22, 2018

From DouglasBoubert in this discourse thread reported:

The user guide (stan-reference-2.17.0.pdf) describes the inc_beta function as being the first integral in section F.2. Stan actually implements the inc_beta function as the second integral, i.e. as the regularised incomplete beta function.

This is the same design choice made in several other languages (for instance, scipy implements it this way), but

  • the documentation should make this clear!

@mitzimorris
Copy link
Member

mitzimorris commented Sep 26, 2018

  • could you please make the language in the reference manual w/r/t reserved words and variable names completely unambiguous - I was confused by this one:
Variable names will not conflict with the following block identifiers,

functions, model, data, parameters, quantities,
transformed, generated

I interpreted "will not conflict" in the opposite way from its intended meaning - i.e., I thought that you could name variables data and that wouldn't be a conflict. how about the following:

The following block identifiers are reserved and cannot be used as variable names:

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Oct 17, 2018

  • update http:// links to https:// for mc-stan.org, github.com, and discourse.mc-stan.org.

This was originally submitted by @junpenglao as PR stan-dev/stan#2624 before the docs were moved to R markdown.

@mitzimorris mitzimorris transferred this issue from stan-dev/stan Dec 23, 2018
@mitzimorris
Copy link
Member

[x] Figure 23.1: Update note: "cholesky_factor_cov[K] ... are only assignable to matrices of dimensions matrix[K, K]. Update to account for generalization of choleskey_factor_cov to rectangular matrices. Perhaps update the cholesky_factor_cov row in the table. I searched for choelesky_factor_cov in the manual and didn't see any other cases in which it was stated that the matrix must be square for this type.

added explanation of use of variable K, M, and N to discussion in following paragraph.

@mitzimorris
Copy link
Member

Originally from @ryan-richt onn stan-dev/stan#2617

I'm not sure what the rest of the sentence is supposed to be, but the suspense is killing me ;-)

FYI:

https://github.com/stan-dev/stan/blob/01a09e735e2d0f880ab9219d469afce18d1b1934/src/docs/users-guide/examples.tex#L3342

The transformed parameter Sigma could be defined as a local variable within the model block if it does not need to be included in the sampler's output.

@ryan-richt
Copy link

ryan-richt commented Jan 14, 2019

Summary:

  • qr_R doc text has an error

Description:

Currently it reads:

matrix qr_R(matrix A)
The upper trapezoidal matrix in the fat QR decomposition of A, 
which implies that the resulting matrix will be square with the same number of rows as A

I think that the last part should say "...the resulting matrix will be rectangular with the same dimensions as A"

Additional Information:

If I run the program:

data {
  int n;
  int p;
  matrix[n,p] ss_v1;
}
model {
}
generated quantities {
  matrix[n,p] foo;
  {
    foo = qr_R(ss_v1);
  }
}

with Data:

  val matrix = Seq[Seq[Double]](Seq(17, 9, 13), Seq(9, 22, 31), Seq(13, 31, 50), Seq(1, 4, 9), Seq(8, 20, 36), Seq(21, 48, 81))

I get back the rectangular matrix:

Vector(
  Vector(32.3265, 59.5797, 97.3815), 
  Vector(-0.0, 26.3868, 45.1378), 
  Vector(-0.0, -0.0, 6.88628), 
  Vector(0.0, 0.0, 0.0), 
  Vector(0.0, 0.0, 0.0), 
  Vector(0.0, 0.0, 0.0)
)

Which seems to confirm the change. If I change the dimensions of the generated quantity to be N x N or P x P, it does not compile in CmdStan.

Current Version:

v2.18.0

@mitzimorris
Copy link
Member

[ ] explain why hierarchical models don't have MLEs other than when given zero-avoiding priors

this would require some plots - specifically?

@mitzimorris
Copy link
Member

mitzimorris commented Jan 15, 2019

  • from jjramsey -

Thanks, @jjramsey. That'll be easy to fix. I should do a general search for non-ASCII characters.

searched all Rmd files for non-ASCII characters using magic find/grep incantation:

find . -name "*.Rmd" -print -exec ggrep --color='auto' -P -n "[^\x00-\x7F]" {} \;
(ggrep == homebrew's install of grep for Mac OSX)

@mitzimorris
Copy link
Member

mitzimorris commented Jan 25, 2019

Hi! Just reporting a minor typo in time-series.Rmd

heteroscedasticity: ### they allow the scale of the noise terms

@zottelef
Copy link

zottelef commented Feb 1, 2019

In the Multi-Logit Regression section of the Stan User's Guide
the line:

y[n] ~ categorical_logit(x_beta[n]);

should be changed in

y[n] ~ categorical_logit(x_beta[n]');

to avoid a SYNTAX ERROR.
Moreover to be coherent with the text that states a normal(0,5) prior on beta, the line

to_vector(beta) ~ normal(0, 2);

should be changed to

to_vector(beta) ~ normal(0, 5);

@bob-carpenter
Copy link
Contributor Author

Thanks, @zottelef. We'll fix those. We're trying to figure out how to do syntax checking on all the fragments without having to write our own manual infrastructure.

@mitzimorris
Copy link
Member

to be coherent with the text that states a normal(0,5) prior on beta

more subtle problem to address is checking recommendations for priors are up-to-date and that priors in code match recommendations

@lwiklendt
Copy link

lwiklendt commented Feb 14, 2019

Under "Dropping uniform mixture ratios" in the "Finite Mixtures" chapter, a mixing ratio of 0.5 is modelled as negative log half. Should this be positive log half?

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Feb 14, 2019 via email

@bob-carpenter
Copy link
Contributor Author

bob-carpenter commented Feb 21, 2019

@mitzimorris
Copy link
Member

mitzimorris commented Mar 21, 2019

The hyperlink to the section Priors for Gaussian Process Parameters in the users guide for 2.18 is not working.
Search for "Priors for Gaussian Process Parameters {#priors-gp.section}" and you will see the problem. I think this is only a problem in the html version.

@mitzimorris
Copy link
Member

closing this issue and opening a new one for 2.19.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants