-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into additional_distributions
- Loading branch information
Showing
82 changed files
with
2,274 additions
and
103 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
^.*\.Rproj$ | ||
^\.Rproj\.user$ | ||
^\.github$ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
*.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# 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] | ||
pull_request: | ||
branches: [master] | ||
|
||
name: R-CMD-check | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | ||
cancel-in-progress: true | ||
|
||
|
||
jobs: | ||
R-CMD-check: | ||
runs-on: ${{ matrix.config.os }} | ||
|
||
name: ${{ matrix.config.os }} (${{ matrix.config.r }}) | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
config: | ||
- {os: macos-latest, r: 'release', rtools: ''} | ||
#- {os: windows-latest, r: 'release', rtools: '42'} | ||
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release', rtools: ''} | ||
- {os: ubuntu-latest, r: 'release', rtools: ''} | ||
- {os: ubuntu-latest, r: 'oldrel-1', rtools: ''} | ||
|
||
env: | ||
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | ||
R_KEEP_PKG_SOURCE: yes | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: r-lib/actions/setup-r@v2 | ||
with: | ||
r-version: ${{ matrix.config.r }} | ||
rtools-version: ${{ matrix.config.rtools }} | ||
http-user-agent: ${{ matrix.config.http-user-agent }} | ||
use-public-rspm: true | ||
|
||
- uses: r-lib/actions/setup-r-dependencies@v2 | ||
with: | ||
extra-packages: | | ||
any::rcmdcheck | ||
any::BH | ||
any::RcppEigen | ||
needs: check | ||
|
||
- uses: r-lib/actions/check-r-package@v2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# 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] | ||
pull_request: | ||
branches: [master] | ||
|
||
name: test-coverage | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | ||
cancel-in-progress: true | ||
|
||
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 | ||
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 | ||
|
||
- name: Upload coverage reports to Codecov | ||
uses: codecov/codecov-action@v3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,9 @@ Date: 2022-10-26 | |
Authors@R: | ||
c(person("Maximilian", "Scholz", email = "[email protected]", | ||
role = c("aut", "cre")), | ||
person("Yannick", "Dzubba", role = c("ctb"))) | ||
person("Paul-Christian", "Bürkner", email = "[email protected]", | ||
role = c("aut")), | ||
person("Yannick", "Dzubba", role = c("aut"))) | ||
Maintainer: Maximilian Scholz <[email protected]> | ||
License: GPL-3 + file LICENSE | ||
Encoding: UTF-8 | ||
|
@@ -16,12 +18,14 @@ Imports: | |
stats, | ||
lamW | ||
Suggests: | ||
dplyr, | ||
testthat (>= 3.1.0), | ||
rmutil, | ||
extraDistr, | ||
BBmisc, | ||
posterior (>= 1.3.1) | ||
posterior (>= 1.3.1), | ||
gnorm, | ||
logitnorm | ||
Remotes: | ||
paul-buerkner/brms | ||
RoxygenNote: 7.2.3 | ||
NeedsCompilation: no | ||
URL: https://github.com/sims1253/bayesfam | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#' Custom rexgauss with default values | ||
#' | ||
#' @param n Number of sampels to draw, has to be a scalar natural | ||
#' @param mu Mean argument, mu unbound | ||
#' @param sigma Shape parameter, sigma > 0 | ||
#' @param beta Shape parameter, beta > 0 | ||
#' | ||
#' @return Vector of length n in exgaussian distribution | ||
#' @export | ||
#' | ||
#' @examples hist(rexgauss_mean(100, 1, 2, 1)) | ||
rexgauss_mean <- function(n, mu = 0, sigma = 1, beta = 1) { | ||
if(isTRUE(any(sigma <= 0))) { | ||
stop("sigma has to be bigger than 0") | ||
} | ||
if(isTRUE(any(beta <= 0))) { | ||
stop("beta has to be bigger than 0") | ||
} | ||
return(brms::rexgaussian(n, mu, sigma, beta)) | ||
} |
Oops, something went wrong.