stan-dev / stan-dev/math

multiple outputs of RNGs

Open
#1,746 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
839
Forks
220
Avg merge
2d 4h
Merged PRs (30d)
14

Description

It would be nice to have new RNG functions that generate more than one draw at a time. E.g.,

generated quantities {
  int y[N];
  y <- poisson_rng(N, lambda);
}

instead of

generated quantities {
  int y[N];
  for (n in 1:N)
    y[n] <- poisson_rng(lambda);
}
  • add to Stan Math
  • add to Stan language
  • add tests for language parsability

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source files or entry points are named. Start by reviewing the existing Stan Math RNG functions and the Stan language handling for generated quantities, then determine how vector-valued RNGs should be represented. Done means the functionality is added to Stan Math and the Stan language, with tests confirming the syntax is parsable.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.