Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
d85d397
prep for release
jgabry Nov 10, 2022
333337e
Update R-CMD-check.yaml
jgabry Nov 10, 2022
0098fbd
update R-CMD-check.yaml
jgabry Nov 10, 2022
2a576cc
test-coverage.yaml
jgabry Nov 10, 2022
428c2c3
Update R-CMD-check.yaml
jgabry Nov 10, 2022
78b38aa
Update R-CMD-check.yaml
jgabry Nov 11, 2022
0ab361c
Update test-coverage.yaml
jgabry Nov 11, 2022
bd8cb0e
update snapshots
jgabry Nov 11, 2022
89c1228
linewidth argument for latest ggplot2 release
jgabry Nov 11, 2022
58349b5
ECDF plots default changed to: plot_diff = FALSE
TeemuSailynoja Nov 11, 2022
554ca31
ECDF plots: interpolate_adj default depends on K
TeemuSailynoja Nov 11, 2022
4c36315
add previous changes to the ppc-pit-ecdf-grouped
TeemuSailynoja Nov 11, 2022
493d30e
..density.. -> after_stat(density)
jgabry Nov 11, 2022
0898f60
Merge branch 'patch-for-cran' of github.com:stan-dev/bayesplot into p…
TeemuSailynoja Nov 11, 2022
fd9b08a
update testthat snapshot
jgabry Nov 11, 2022
0d3b5da
update tests + snapshots
jgabry Nov 11, 2022
f38d063
size -> linewidth in a few more places
jgabry Nov 11, 2022
8b0c385
more work on aes_ and .data in tidyselect deprecations
jgabry Nov 12, 2022
cdad5d1
more ggplot2/tidyselect deprecation fixes
jgabry Nov 12, 2022
2c5cda0
more ggplot2/tidyselect deprecation fixes
jgabry Nov 12, 2022
1f11bdf
update more snapshots
jgabry Nov 12, 2022
31c7fd5
Update R-CMD-check.yaml
jgabry Nov 12, 2022
e2a7908
run test coverage on this branch
jgabry Nov 13, 2022
d562b37
update sysdata.rda
jgabry Nov 13, 2022
998b4b9
Merge pull request #292 from stan-dev/aes_-deprecation
jgabry Nov 13, 2022
b9f1a14
use '.' prefix for internal objects in R/sysdata.rda
jgabry Nov 13, 2022
dc91b58
shorten examples runtime for r cmd check
jgabry Nov 13, 2022
1122b4b
Update NEWS.md
jgabry Nov 13, 2022
eba3bc5
Update DESCRIPTION
jgabry Nov 13, 2022
aa445ae
try skipping vignette using RStan on GHA Windows runs
jgabry Nov 14, 2022
e77b702
run GHA without testthat/snaps_ in .Rbuildignore
jgabry Nov 14, 2022
7acf04d
shorten file names in snaps_ to avoid NOTE
jgabry Nov 14, 2022
679fada
visual tests for scatter, parcoord, acf, recover
jgabry Nov 14, 2022
1416202
update mcmc-recover snapshots
jgabry Nov 14, 2022
b38d468
visual test for mcmc_pairs
jgabry Nov 14, 2022
6669943
mcmc_pairs: >= max_treedepth instead of > max_treedepth
jgabry Nov 14, 2022
45ee422
Update NEWS.md
jgabry Nov 14, 2022
fbd03e9
visual tests for mcmc_pairs
jgabry Nov 14, 2022
e29dc78
visual tests for mcmc-nuts and ppc-loo
jgabry Nov 15, 2022
609b4ee
update roxygen2
jgabry Nov 15, 2022
e8e3d49
make nuts plots compatible with updates to grid graphics
jgabry Nov 15, 2022
31940cb
remove unused code and improve test coverage
jgabry Nov 15, 2022
10eac64
update doc and snaps
jgabry Nov 15, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,3 @@ book/*
docs/*
Rplots.pdf
^\.github$
^tests/testthat/_snaps$
102 changes: 26 additions & 76 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
push:
branches:
- master
branches: [main, master]
pull_request:
branches:
- master
branches: [main, master, patch-for-cran]

name: R-CMD-check

jobs:
R-CMD-check:
if: "! contains(github.event.head_commit.message, '[ci skip]')"
runs-on: ${{ matrix.config.os }}

name: ${{ matrix.config.os }} (${{ matrix.config.r }})
Expand All @@ -19,85 +18,36 @@ jobs:
fail-fast: false
matrix:
config:
- {os: macos-latest, r: 'release'}
- {os: windows-latest, r: 'release'}
- {os: macOS-latest, r: 'release'}
- {os: ubuntu-20.04, r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}
- {os: ubuntu-20.04, r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
- {os: ubuntu-latest, r: 'release'}
- {os: ubuntu-latest, r: 'oldrel-1'}

env:
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
RSPM: ${{ matrix.config.rspm }}
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@master
- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
use-public-rspm: true

- uses: r-lib/actions/setup-pandoc@master

- name: Query dependencies
run: |
install.packages('remotes')
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2)
writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version")
shell: Rscript {0}

- name: Cache R packages
if: runner.os != 'Windows'
uses: actions/cache@v1
- uses: r-lib/actions/setup-r-dependencies@v2
with:
path: ${{ env.R_LIBS_USER }}
key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-${{ hashFiles('.github/depends.Rds') }}
restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-

- name: Install system dependencies for linux
if: runner.os == 'Linux'
env:
RHUB_PLATFORM: linux-x86_64-ubuntu-gcc
run: |
Rscript -e "remotes::install_github('r-hub/sysreqs')"
sysreqs=$(Rscript -e "cat(sysreqs::sysreq_commands('DESCRIPTION'))")
sudo -s eval "$sysreqs"

- name: Install system dependencies for mac
if: runner.os == 'MacOS'
run: |
curl -sL https://mac.r-project.org/libs-4/ |
sed -n 's/.*href=\([^>]*x86_64.tar.gz\).*/\1/p' |
xargs -I % sh -c 'curl https://mac.r-project.org/libs-4/% --output %; sudo tar fvxz % -C /usr/local --strip 2'
ls -la /usr/local/lib
ls -la /usr/local/include

- name: Install dependencies
run: |
remotes::install_deps(dependencies = TRUE)
remotes::install_cran("rcmdcheck")
shell: Rscript {0}

- name: Session info
run: |
options(width = 100)
pkgs <- installed.packages()[, "Package"]
sessioninfo::session_info(pkgs, include_base = TRUE)
shell: Rscript {0}

- name: Check
env:
_R_CHECK_CRAN_INCOMING_: false
_R_CHECK_FORCE_SUGGESTS_: false
run: rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
shell: Rscript {0}

- name: Show testthat output
if: always()
run: find check -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash

- name: Upload check results
if: failure()
uses: actions/upload-artifact@master
extra-packages: |
any::rcmdcheck
any::BH
any::RcppEigen
any::vdiffr
needs: check

- uses: r-lib/actions/check-r-package@v2
with:
name: ${{ runner.os }}-r${{ matrix.config.r }}-results
path: check
upload-snapshots: true
46 changes: 0 additions & 46 deletions .github/workflows/codecov.yaml

This file was deleted.

52 changes: 52 additions & 0 deletions .github/workflows/test-coverage.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
push:
branches: [main, master]
pull_request:
branches: [main, master, patch-for-cran]

name: test-coverage

jobs:
test-coverage:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v3

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: |
any::covr
any::vdiffr
needs: coverage

- name: Test coverage
run: |
covr::codecov(
quiet = FALSE,
clean = FALSE,
install_path = file.path(Sys.getenv("RUNNER_TEMP"), "package")
)
shell: Rscript {0}

- name: Show testthat output
if: always()
run: |
## --------------------------------------------------------------------
find ${{ runner.temp }}/package -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash

- name: Upload test results
if: failure()
uses: actions/upload-artifact@v3
with:
name: coverage-test-failures
path: ${{ runner.temp }}/package
7 changes: 4 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
Package: bayesplot
Type: Package
Title: Plotting for Bayesian Models
Version: 1.9.0.9000
Date: 2022-03-09
Version: 1.10.0
Date: 2022-11-15
Authors@R: c(person("Jonah", "Gabry", role = c("aut", "cre"), email = "jsg2201@columbia.edu"),
person("Tristan", "Mahr", role = "aut"),
person("Paul-Christian", "Bürkner", role = "ctb"),
person("Martin", "Modrák", role = "ctb"),
person("Malcolm", "Barrett", role = "ctb"),
person("Frank", "Weber", role = "ctb"),
person("Eduardo", "Coronado Sroka", role = "ctb"),
person("Teemu", "Sailynoja", role = "ctb"),
person("Aki", "Vehtari", role = "ctb"))
Maintainer: Jonah Gabry <jsg2201@columbia.edu>
Description: Plotting functions for posterior analysis, MCMC diagnostics,
Expand Down Expand Up @@ -54,7 +55,7 @@ Suggests:
survival,
testthat (>= 2.0.0),
vdiffr (>= 1.0.2)
RoxygenNote: 7.1.2
RoxygenNote: 7.2.2
VignetteBuilder: knitr
Encoding: UTF-8
Roxygen: list(markdown = TRUE)
3 changes: 1 addition & 2 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@ import(rlang)
import(stats)
importFrom(dplyr,"%>%")
importFrom(dplyr,across)
importFrom(dplyr,all_of)
importFrom(dplyr,arrange)
importFrom(dplyr,count)
importFrom(dplyr,full_join)
Expand All @@ -205,5 +206,3 @@ importFrom(dplyr,top_n)
importFrom(dplyr,ungroup)
importFrom(dplyr,vars)
importFrom(ggplot2,"%+replace%")
importFrom(ggridges,geom_density_ridges)
importFrom(ggridges,geom_density_ridges2)
17 changes: 14 additions & 3 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,19 @@
<!-- See http://style.tidyverse.org/news.html for advice on writing news -->

# bayesplot 1.9.0.9000

Items for next release go here
# bayesplot 1.10.0

* New function `mcmc_rank_ecdf()` for rank ecdf plots with confidence bands for
assessing if two or more chains sample the same distribution (#282,
@TeemuSailynoja)
* New functions `ppc_pit_ecdf()`, `ppc_pit_ecdf_grouped()`, PIT ecdf plots with
confidence bands to assess if `y` and `yrep` contain samples from the same
distribution. (#282, @TeemuSailynoja)
* Several `ppc` and `ppd` functions now accept the new `linewidth` argument
introduced in ggplot2 3.4.0: `ppc_bars()`, `ppc_bars_grouped()`,
`ppc_intervals()`, `ppc_intervals_grouped()`, `ppd_intervals()`,
`ppd_intervals_grouped()`.
* Fix bug in how `mcmc_pairs()` detected hitting `max_treedepth`, thanks to @dmphillippo. (#281)
* Fix failing tests due to changes in ggplot2 3.4.0 (#289)

# bayesplot 1.9.0

Expand Down
4 changes: 2 additions & 2 deletions R/bayesplot-colors.R
Original file line number Diff line number Diff line change
Expand Up @@ -221,12 +221,12 @@ plot_scheme <- function(scheme = NULL) {
value = rep(1, length(x))
)

ggplot(color_data, aes_(x = ~ name, y = ~ value, fill = ~ group)) +
ggplot(color_data, aes(x = .data$name, y = .data$value, fill = .data$group)) +
geom_bar(
width = .5,
stat = "identity",
color = "white",
size = 0.1
linewidth = 0.1
) +
scale_fill_manual("", values = unlist(x)) +
theme_void() +
Expand Down
4 changes: 2 additions & 2 deletions R/bayesplot-ggplot-themes.R
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ theme_default <-
panel.grid = element_blank(),
panel.background = element_blank(),
panel.border = element_blank(),
axis.line = element_line(size = 0.4),
axis.ticks = element_line(size = 0.3),
axis.line = element_line(linewidth = 0.4),
axis.ticks = element_line(linewidth = 0.3),
strip.background = element_blank(),
strip.text = element_text(size = rel(0.9)),
strip.placement = "outside",
Expand Down
Loading