Skip to content
Daniel Turek edited this page Aug 16, 2018 · 19 revisions

The following stylistic guidelines apply to all files relating to the MCMC engine (those with matching MCMC_*.R) of the NIMBLE software package

Code

  • Four spaces indentation
  • All code is properly indented
  • Assignments exclusively take place using the left arrow (<-), and never an equal sign
  • Generally use camelCase for variable names
  • Avoid periods (.) in variable names at all costs
  • Code blocks begin with a single space preceding the open-curly-brace, as:
if(...) {
    ....
}

Comments

  • Full line comments begin with double-hash (##)
  • Comments at the end a code line may begin with either single- or double-hash
  • Comments follow same indentation as code
  • Avoid lengthy block comments, when possible
  • Brief historical comments are ok, and should include initials and date

Other

  • The MCMC Team favours the imperial spelling
  • Defer remaining questions to [email protected]
Clone this wiki locally