Skip to content

Commit

Permalink
Merge pull request #31 from nimble-dev/joss
Browse files Browse the repository at this point in the history
Fix vignette formatting detail.  Add some DOIs to paper.bib.
  • Loading branch information
perrydv authored Jan 12, 2022
2 parents df5bf10 + cee9f1e commit 3b308da
Show file tree
Hide file tree
Showing 16 changed files with 69 additions and 67 deletions.
10 changes: 5 additions & 5 deletions compareMCMCs/doc/compareMCMCs.R
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ res$nimble$metrics
MCMCmetric_quartiles <- function(result, options) {
p25 <- apply(result$samples, 2, quantile, probs = 0.25)
p75 <- apply(result$samples, 2, quantile, probs = 0.75)
## q25 and q75 are named vectors with names matching model parameters
## i.e. column names of result$samples
# q25 and q75 are named vectors with names matching model parameters
# i.e. column names of result$samples
maxDiff <- max(p75-p25)
list(byParameter = list(p25 = p25,
p75 = p75),
Expand Down Expand Up @@ -133,8 +133,8 @@ res <- compareMCMCs(modelInfo,
niter = 2000,
burnin = 100))

## We will look at the result using combineMetrics
## rather than generating new html pages.
# We will look at the result using combineMetrics
# rather than generating new html pages.
combineMetrics(res)

## -----------------------------------------------------------------------------
Expand All @@ -145,7 +145,7 @@ conversions <- list(nimble = reparam,
applyConversions(res, conversions)
clearMetrics(res)
addMetrics(res) # use default metrics
combineMetrics(res) ## An easy way to see that it worked
combineMetrics(res) # An easy way to see that it worked

## -----------------------------------------------------------------------------
combineMetrics(res, include_times = TRUE)
Expand Down
10 changes: 5 additions & 5 deletions compareMCMCs/doc/compareMCMCs.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -203,8 +203,8 @@ Let's look at an example of each. Say we want to make a metric that calculates
MCMCmetric_quartiles <- function(result, options) {
p25 <- apply(result$samples, 2, quantile, probs = 0.25)
p75 <- apply(result$samples, 2, quantile, probs = 0.75)
## q25 and q75 are named vectors with names matching model parameters
## i.e. column names of result$samples
# q25 and q75 are named vectors with names matching model parameters
# i.e. column names of result$samples
maxDiff <- max(p75-p25)
list(byParameter = list(p25 = p25,
p75 = p75),
Expand Down Expand Up @@ -254,8 +254,8 @@ res <- compareMCMCs(modelInfo,
niter = 2000,
burnin = 100))
## We will look at the result using combineMetrics
## rather than generating new html pages.
# We will look at the result using combineMetrics
# rather than generating new html pages.
combineMetrics(res)
```

Expand All @@ -273,7 +273,7 @@ conversions <- list(nimble = reparam,
applyConversions(res, conversions)
clearMetrics(res)
addMetrics(res) # use default metrics
combineMetrics(res) ## An easy way to see that it worked
combineMetrics(res) # An easy way to see that it worked
```

## How to specify conversions
Expand Down
102 changes: 51 additions & 51 deletions compareMCMCs/doc/compareMCMCs.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions compareMCMCs/doc/example1.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ <h1>example1</h1>
<a href='#p4'>MCMC efficiency details</a><br>
<a href='#p5'>Posterior summaries</a><br><h2 id='p1'>MCMC sampling time</h2>
<!-- html table generated in R 4.1.2 by xtable 1.8-4 package -->
<!-- Fri Jan 7 14:52:53 2022 -->
<!-- Wed Jan 12 15:21:55 2022 -->
<table border=1>
<tr> <th> MCMC </th> <th> burnin </th> <th> post-burnin </th> <th> total sampling </th> </tr>
<tr> <td> jags </td> <td align="right"> 0.00 </td> <td align="right"> 0.01 </td> <td align="right"> 0.01 </td> </tr>
<tr> <td> stan </td> <td align="right"> 0.00 </td> <td align="right"> 0.07 </td> <td align="right"> 0.07 </td> </tr>
<tr> <td> stan </td> <td align="right"> 0.01 </td> <td align="right"> 0.07 </td> <td align="right"> 0.08 </td> </tr>
<tr> <td> nimble </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> </tr>
<tr> <td> nimble_slice </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> </tr>
</table>
Expand Down
Binary file modified compareMCMCs/doc/example1_efficiencyDetails.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified compareMCMCs/doc/example1_efficiencySummaryAll.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified compareMCMCs/doc/example1_paceSummaryAll.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified compareMCMCs/doc/example1_posteriorSummary.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions compareMCMCs/doc/example2.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ <h1>example2</h1>
<a href='#p4'>MCMC efficiency details</a><br>
<a href='#p5'>Posterior summaries</a><br><h2 id='p1'>MCMC sampling time</h2>
<!-- html table generated in R 4.1.2 by xtable 1.8-4 package -->
<!-- Fri Jan 7 14:53:09 2022 -->
<!-- Wed Jan 12 15:22:10 2022 -->
<table border=1>
<tr> <th> MCMC </th> <th> burnin </th> <th> post-burnin </th> <th> total sampling </th> </tr>
<tr> <td> jags </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> </tr>
<tr> <td> jags </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> <td align="right"> 0.01 </td> </tr>
<tr> <td> nimble </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> <td align="right"> 0.00 </td> </tr>
<tr> <td> nimble_slice </td> <td align="right"> 0.00 </td> <td align="right"> 0.01 </td> <td align="right"> 0.01 </td> </tr>
</table>
Expand Down
Binary file modified compareMCMCs/doc/example2_efficiencyDetails.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified compareMCMCs/doc/example2_efficiencySummaryAll.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified compareMCMCs/doc/example2_paceSummaryAll.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified compareMCMCs/doc/example2_posteriorSummary.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added compareMCMCs/vignettes/.DS_Store
Binary file not shown.
4 changes: 2 additions & 2 deletions compareMCMCs/vignettes/compareMCMCs.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -203,8 +203,8 @@ Let's look at an example of each. Say we want to make a metric that calculates
MCMCmetric_quartiles <- function(result, options) {
p25 <- apply(result$samples, 2, quantile, probs = 0.25)
p75 <- apply(result$samples, 2, quantile, probs = 0.75)
## q25 and q75 are named vectors with names matching model parameters
## i.e. column names of result$samples
# q25 and q75 are named vectors with names matching model parameters
# i.e. column names of result$samples
maxDiff <- max(p75-p25)
list(byParameter = list(p25 = p25,
p75 = p75),
Expand Down
2 changes: 2 additions & 0 deletions paper.bib
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ @article{lunn2009bugs
number = {25},
pages = {3049--3067},
year = {2009},
doi = {10.1002/sim.3680},
publisher = {Wiley Online Library}
}

Expand All @@ -93,6 +94,7 @@ @article{lunn2000winbugs
number = {4},
pages = {325--337},
year = {2000},
doi = {10.1023/A:1008929526011},
publisher = {Springer}
}

Expand Down

0 comments on commit 3b308da

Please sign in to comment.