From 0613471a5daf8bf6dc22ee5e1b2f49dc284a9810 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Thu, 19 Sep 2024 06:57:34 -0600 Subject: [PATCH 01/10] updated actions --- .github/workflows/R-CMD-check.yaml | 43 +++++++++++----------------- .github/workflows/pkgdown.yaml | 6 ++-- .github/workflows/test-coverage.yaml | 23 +++++++++++---- README.Rmd | 2 +- README.md | 2 +- 5 files changed, 39 insertions(+), 37 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 868b0da..ec753b1 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -1,19 +1,20 @@ # 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 - +# +# NOTE: This workflow is overkill for most R packages and +# check-standard.yaml is likely a better choice. +# usethis::use_github_action("check-standard") will install it. on: push: branches: [main, master] pull_request: branches: [main, master] - schedule: - - cron: '0 8 * * 0' - name: R-CMD-check +permissions: read-all + jobs: R-CMD-check: - if: "!contains(github.event.head_commit.message, 'skip ci')" runs-on: ${{ matrix.config.os }} name: ${{ matrix.config.os }} (${{ matrix.config.r }}) @@ -25,24 +26,22 @@ jobs: - {os: macos-latest, r: 'release'} - {os: windows-latest, r: 'release'} - # Use 3.6 to trigger usage of RTools35 - - {os: windows-latest, r: '3.6'} - # use 4.1 to check with rtools40's older compiler - - {os: windows-latest, r: '4.1'} + # use 4.0 or 4.1 to check with rtools40's older compiler + - {os: windows-latest, r: 'oldrel-4'} - - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} - - {os: ubuntu-latest, r: 'release'} - - {os: ubuntu-latest, r: 'oldrel-1'} - - {os: ubuntu-latest, r: 'oldrel-2'} - - {os: ubuntu-latest, r: 'oldrel-3'} - - {os: ubuntu-latest, r: 'oldrel-4'} + - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} + - {os: ubuntu-latest, r: 'release'} + - {os: ubuntu-latest, r: 'oldrel-1'} + - {os: ubuntu-latest, r: 'oldrel-2'} + - {os: ubuntu-latest, r: 'oldrel-3'} + - {os: ubuntu-latest, r: 'oldrel-4'} env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} R_KEEP_PKG_SOURCE: yes steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-pandoc@v2 @@ -60,14 +59,4 @@ jobs: - uses: r-lib/actions/check-r-package@v2 with: upload-snapshots: true - - - name: action-slack - if: failure() - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - uses: 8398a7/action-slack@v3.0.0 - with: - status: ${{ job.status }} - author_name: "github action: ${{github.workflow}}" - fields: repo, ref, commit, author, message - + build_args: 'c("--no-manual","--compact-vignettes=gs+qpdf")' diff --git a/.github/workflows/pkgdown.yaml b/.github/workflows/pkgdown.yaml index ed7650c..c9f0165 100644 --- a/.github/workflows/pkgdown.yaml +++ b/.github/workflows/pkgdown.yaml @@ -11,6 +11,8 @@ on: name: pkgdown +permissions: read-all + jobs: pkgdown: runs-on: ubuntu-latest @@ -22,7 +24,7 @@ jobs: permissions: contents: write steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-pandoc@v2 @@ -41,7 +43,7 @@ jobs: - name: Deploy to GitHub pages 🚀 if: github.event_name != 'pull_request' - uses: JamesIves/github-pages-deploy-action@v4.4.1 + uses: JamesIves/github-pages-deploy-action@v4.5.0 with: clean: false branch: gh-pages diff --git a/.github/workflows/test-coverage.yaml b/.github/workflows/test-coverage.yaml index 2c5bb50..fefc52e 100644 --- a/.github/workflows/test-coverage.yaml +++ b/.github/workflows/test-coverage.yaml @@ -8,6 +8,8 @@ on: name: test-coverage +permissions: read-all + jobs: test-coverage: runs-on: ubuntu-latest @@ -15,7 +17,7 @@ jobs: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-r@v2 with: @@ -23,28 +25,37 @@ jobs: - uses: r-lib/actions/setup-r-dependencies@v2 with: - extra-packages: any::covr + extra-packages: any::covr, any::xml2 needs: coverage - name: Test coverage run: | - covr::codecov( + cov <- covr::package_coverage( quiet = FALSE, clean = FALSE, - install_path = file.path(Sys.getenv("RUNNER_TEMP"), "package") + install_path = file.path(normalizePath(Sys.getenv("RUNNER_TEMP"), winslash = "/"), "package") ) + covr::to_cobertura(cov) shell: Rscript {0} + - uses: codecov/codecov-action@v4 + with: + fail_ci_if_error: ${{ github.event_name != 'pull_request' && true || false }} + file: ./cobertura.xml + plugin: noop + disable_search: true + token: ${{ secrets.CODECOV_TOKEN }} + - name: Show testthat output if: always() run: | ## -------------------------------------------------------------------- - find ${{ runner.temp }}/package -name 'testthat.Rout*' -exec cat '{}' \; || true + find '${{ runner.temp }}/package' -name 'testthat.Rout*' -exec cat '{}' \; || true shell: bash - name: Upload test results if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: coverage-test-failures path: ${{ runner.temp }}/package diff --git a/README.Rmd b/README.Rmd index 7027663..3d978f2 100644 --- a/README.Rmd +++ b/README.Rmd @@ -17,7 +17,7 @@ knitr::opts_chunk$set( [![Lifecycle: stable](https://img.shields.io/badge/lifecycle-stable-brightgreen.svg)](https://lifecycle.r-lib.org/articles/stages.html#stable) [![R-CMD-check](https://github.com/poissonconsulting/nlist/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/poissonconsulting/nlist/actions/workflows/R-CMD-check.yaml) -[![Codecov test coverage](https://codecov.io/gh/poissonconsulting/nlist/branch/master/graph/badge.svg)](https://codecov.io/gh/poissonconsulting/nlist?branch=master) +[![Codecov test coverage](https://codecov.io/gh/poissonconsulting/nlist/graph/badge.svg)](https://app.codecov.io/gh/poissonconsulting/nlist) [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT) [![CRAN status](https://www.r-pkg.org/badges/version/nlist)](https://cran.r-project.org/package=nlist) ![CRAN downloads](http://cranlogs.r-pkg.org/badges/nlist) diff --git a/README.md b/README.md index a11f2c4..60acb96 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ stable](https://img.shields.io/badge/lifecycle-stable-brightgreen.svg)](https://lifecycle.r-lib.org/articles/stages.html#stable) [![R-CMD-check](https://github.com/poissonconsulting/nlist/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/poissonconsulting/nlist/actions/workflows/R-CMD-check.yaml) [![Codecov test -coverage](https://codecov.io/gh/poissonconsulting/nlist/branch/master/graph/badge.svg)](https://codecov.io/gh/poissonconsulting/nlist?branch=master) +coverage](https://codecov.io/gh/poissonconsulting/nlist/graph/badge.svg)](https://app.codecov.io/gh/poissonconsulting/nlist) [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT) [![CRAN From 6b069d87ce56dfba34d8c9ba39159e90057ab465 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Thu, 19 Sep 2024 07:00:48 -0600 Subject: [PATCH 02/10] pkgdown --- pkgdown/favicon/apple-touch-icon-120x120.png | Bin 0 -> 9977 bytes pkgdown/favicon/apple-touch-icon-60x60.png | Bin 0 -> 4475 bytes pkgdown/favicon/apple-touch-icon-76x76.png | Bin 0 -> 5841 bytes pkgdown/favicon/apple-touch-icon.png | Bin 0 -> 9977 bytes pkgdown/favicon/favicon-16x16.png | Bin 0 -> 1239 bytes pkgdown/favicon/favicon-32x32.png | Bin 0 -> 2203 bytes pkgdown/favicon/favicon.ico | Bin 0 -> 15086 bytes 7 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 pkgdown/favicon/apple-touch-icon-120x120.png create mode 100644 pkgdown/favicon/apple-touch-icon-60x60.png create mode 100644 pkgdown/favicon/apple-touch-icon-76x76.png create mode 100644 pkgdown/favicon/apple-touch-icon.png create mode 100644 pkgdown/favicon/favicon-16x16.png create mode 100644 pkgdown/favicon/favicon-32x32.png create mode 100644 pkgdown/favicon/favicon.ico diff --git a/pkgdown/favicon/apple-touch-icon-120x120.png b/pkgdown/favicon/apple-touch-icon-120x120.png new file mode 100644 index 0000000000000000000000000000000000000000..586c171462b9ae424a2108047e2297f54381c2c4 GIT binary patch literal 9977 zcmZ`)L(tEqRZ-5@4ffldkKkdZ9?=QMDK#Ndhf*QT|@{LQG(bA(YuIf(V`RY z{@-u!hxfV9ow@hUJ#%NyIlptxoiho>hFT;+ih6DgO@^#cz%mWt>Ljy7khq8{E zdYAA0{}dNeJN`JjYdT@-w8WRP`JaBFY9||iC1lpiq99_7-q@0{K=XfoSoCi zZ}rKzArMHavP{|3&v{4Lu$I01DKV$?cX?C#m+<27o!{`uynLd|%O4Ham#ej`R}TQv zrZvK`TzjcQJPs^NGSsi8RpCBL01$HhXEk>-ifLs}qClC)SDMQ4k=E$iykz$hGV@G& zdk2;l-a6kD=CCO4^H8<(tGf;wN1VR?!%Y$bwF>#xpfAGTMS;rk7(^v-Wv@VcOU!NKSnJ7 zf>{2t*o^$ahRIJss!smf^0z#PI>CbCqcS+1AUKK^`nHN>d*fWL3E!I(c0gCqx^DdM z3Ds36>*>*r&6wF`c+e!VXZ$-`Znv`-rlG~J@y0ZM8$WEBeN~!#J>?seTyif+0K8b< zq4>H$^+*ChZg%qO9vwhh6^zc1Ofg$Er+xLX)1j8UWGPUfDYr$td|vbPnrZK?h$G>@ ze_f2<^pmd4D_OH=yyigrO!)c)EPsXgfY{hfQbgEx0A;Or#8ZLTNEk_V4%_E!j^3wP zLn9n%;jF)XB>yPRIz8Of&FO0=1#g~%Q9^bhCF~MnnKQ{8xIe?`vO{TGKNmBR;;?u# zm{;Lw^aJDtxugZ)=JZ_bTpAwCc_mjN(>yW8+$0@-L%Hmde#?mA0qkF z5J9QW9TontsKpYoude4FiAp07pYElO=)RN&<47Zv{kegG3cxFQGCap`H~QnM>@-^M z_z>orIF)`V{w&-{Ki*CJCSE1Q52EcESQ~XamfO};Y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kCo)+YWp)&uIZ>V?(ErkUDges#c_#hk;>&@A zY;Im+`OUt@l`ulsf#-O+lxS)DzWqiOO5%K zdH=f)h&w9MolK2PdQ$wb6=S=rNXEn7iga{_Pl}+)f2GDi8AcSIF}=EndBUnY*os@u zsHwnwHr}|GrE&q*nHpiW+}@;n$WW!q2^;`6x-vv?8(qsT&zpFsqPvi4NT{!Vr*y^H zb@Bd&conm8i^EUD%Fo%+4<-wJ1;bPTQDISW0bv;d5gBt4FPO#wJ;#DY*_N;XQp3@RK-7WD}6L1!GcHglHo`I*tr6Q3DA6O2b_m+A@v Y_8yb_ovKP?VLk!S(J)kRRCS2@AIgBOhyVZp literal 0 HcmV?d00001 diff --git a/pkgdown/favicon/apple-touch-icon-60x60.png b/pkgdown/favicon/apple-touch-icon-60x60.png new file mode 100644 index 0000000000000000000000000000000000000000..03405a2848f27c5f42236d66ce3d17f8127e82d6 GIT binary patch literal 4475 zcmV->5rpoEP)004R>004l5008;`004mK004C`008P>0026e000+ooVrmw00006 zVoOIv0RI600RN!9r;`8x00(qQO+^Rj2@?$f0CA@}8~^|i97#k$RA}DSn|pMX)s?`1 z-}8R=eQ(0egCvHhQHfv`d=+igsrF?nGOHciI&HNt*Nk?x%yg}3=iwS%UDK)7T5H=G z?X00QR4pxbYCDP*(F#Na^Ne!b&BcJO0Y%-}Y97`4@D0D7|h3>JovN@3`F&NB5U6A}Bz*InGSZO6f!`s@v@6Rz8YE}T6b zId;Y7(Oi?r92zKo!58X5Db+`SSS;+&SX)DV%_Jg@gA=kz#$!0Pjpqlrz8?;Roag!C zgY7-}uu|-K?#b-X>K!Zik4GPzFdZkv!iyeXNiq^bL8R>YH%Y0!Dx|tvffceWGF2%i zrIUm#3pIiQt{;%?AD|~Ufb09{AS}~Z7YUg^Xv!ph`|{R$rAmdKY(Kfd0znX9=z7sI^=IQ@`;iM8 ztJ~Up2K}$yGWU%1)yMnd_y1=-N+}{CYpP=#_f_X@nh{R6It=w()!)*AJq8Ag}ZS zdE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q5?cd7$NVBDp+~xli{h4OV)y{(N5s1ZTZvWn4SE$!?xb)ux3Q zHf5=K()qU_k09PE32KzX|H4%kD7`v-_@m0shCO+V3(x3nhMjv-=*t|{63bvYpz7NZ z+9#0%ULe#TFVv~F#@589tQxLudm+WjAqZUxqawLM#b=KE$@moF9%k8=dM-B^U*3%R zwlTf-mwwf*oliftJ*>>O1dLZ6Vft>msRnM*J>%AaYpS z)QW`Xa`ZumQxm|07HrH8_(wgZNg4&%A1j>dIG83`Rn<_15LD1q3m5Z|D zX8bDd^O9#3H6SIkq90d&-oUetU5)a3CS2=%#cCoO zfw4zp92D(59j*}|DK053Dy|?ZpHFa4$ldHg3R*l##6sIy`WknmE8 z*-|Nvo!P?pP#Q*{njQOoDlXR^D(9twN Jl&hm~{{t6<;Qs&s literal 0 HcmV?d00001 diff --git a/pkgdown/favicon/apple-touch-icon.png b/pkgdown/favicon/apple-touch-icon.png new file mode 100644 index 0000000000000000000000000000000000000000..13f3b3b50f0817fa93b0eb62bf873b9963bc20fe GIT binary patch literal 9977 zcmZ`)L$$XE4r+1_1=5$y_b;aWfKxL2+_M>t=>DadKVFbMU)^mLi8>oTD0ix z-T(XT{qR2bxik0Pxo7UoIp=rIxpOAo$Uu{rkd_bt01#_yshMEvfd5Vq9;TFbmiU3G zfG?Ewl>va}WTIOKT+BVQla`4-01(Il0E9;a0N0pD;eP-CKOq2M*B$_n$pHW!dlhsV z%V8Su9CbC-01y8iCEbotd7j@k;L@PFjMQ01I=x4|_{Yabaot;z3 zZuCgGpipRvl62|huQ>;q(B|E{Nm0kN_qmgL7x1F6?LY8|+&sdIi=XvY7b`U^mk$7v z##MsR96QMaTy`uAQq=Fp6`@`V00?^ZcO_>dl5u%gJYR|1M~c$nk><$ioJ7|mGUHTg zYa5mt)-u-^YQG@n{ZP66yQ|hImMCrQ=PL=QlV$MtdOcyjPI6SX`zTU$$RL~S?O!w0 zrscM`)*eXnk;rIW<4OnfstuE$wGpt`CEoF6Gl^hNkX*;M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LG1qg~Mi`f&zImHw#@sPGaPUTuxg>E{nv;A|sY&&l^-nJN~ Z1-q<*jd3XDdxU6{{w7O3Jw4O literal 0 HcmV?d00001 diff --git a/pkgdown/favicon/favicon.ico b/pkgdown/favicon/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..9c35aa7b98a8cfa06cf0146dd1cc84f3adf70512 GIT binary patch literal 15086 zcmdU02~eEJl^#ivwQ*w0wa%uJ*eNNyNhMp^9OW%LRjEqsRJl^?%_f^mPUKjJo!YDq zNw(1iG7^UnNC+VT5<=oW1rmoq+#rqthI1J1Q{uh`5DddL3@~rM*TakkW;lkUcK5I9 z>Hp~Ncl7Jmuitwkk!+Lfko@?^64ZMo(ch6sUXw^9d-pCpzaWvc;oS?U`TGZ7kVst7 z;CpC;E|SA2{9at&)>m8oTM%ad?fjrqzPSN5Q@H`hH3eax2bSKu_&weH?6$3jy^-+? zBhI~$AAI`1fU_dk-)6oz<^q+(xDuXqcwb)_e)i+?gexy@1jbhM1)jU4p=aL84Lp&a z<8LzqJgK$#K255WqVPRv106Qn{1CfbS(Ni{D(+wVyRE>*nlZ~0Jh$hE*#0Ol=#)Qj zQ-Q}+n-xr>eUC^tKTn2>???L|i*MWp^PvX4Va3rd|Jqa#v%?ygo7FZy*!CshVh>z8 za|2FLMdCFYXqD5PR%1ZhtmbdZN0lT`^dig^querx-r!x$qNt2*7Ecx=exC}iq3bixn1YjU@5 zgbu8+uVQXbfH$ouR33kY`kG2n9l^LX+TDy!}f%>AR45L$#Neq+M7j#5vQIzAm;N6#3qoXD> z=nIg+pMv%n;5`ZcQ$t=9jSu%wQ)3e)C#O{wZiTKtqE=q7U~S92_KRegUPYWr#l9zY(w) zW@G*xVjM6ZQ@|?$GWAA%PWVnsbO7I-p!F=;DuF*KQf|_4XFbi&X$603YisFuzx@L_ zI5^Sx_&8~`S~_>mk-WWp=-M@Jva|b~u3z`1{rle~Kfhaace*n3lA0WmzD)J8f>FxcZ&E?Bi=(pfQLwy6Kr)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{A`D>RDW)G%5&xc)|BvTF^r{rH$1NgKKrLfoAQma#OFoxScZ-8k@Ub9Yk*~` zUJv|2{+_(+5O@dLFQTs9KOpi zcl+SGdv-mvuB8wD=kgWs;uEZ)ChP+`E|{NIygv>8J~*qK{ytuD|Y5W5RBdx$#Vo>_3suuBI1iQOG=LFB<5vysAMunWWJzQ}{yf?XEu zt^jQIQ?Mf1i(>RstTCFC_c6BP*|sp)8|>$Xt%DTIkIecDyR4;9?0wvqOF3XK%Kuuf zKlWFKt%NS+{7!=n&9E2g_$B=X|Ik;9a}?*M@t)L<_%-KlvHfW&2M7B!Kz#Ues^_7v z!GEKe8XKnZ?iwSFtiw2t%X{f!`%$k`VN)wIZyx=6w%^h1koBJ{QhXn@<^*ZDp8;3S zZ({q0@!@y;4L~)Bf2H88|3*QCgVEoR;&I?P*iHwLlPiCmeQTb1%ze1;%!{{Bg_@25swP5bB^-~-+Rzb|~hd03f_&~_^oZlhxV>g(_!qwoI!_`^bE literal 0 HcmV?d00001 From 9e2b9a446f4dceb88cf1a6c9c2c51493833d5ed9 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Thu, 19 Sep 2024 07:01:01 -0600 Subject: [PATCH 03/10] updated documentation --- DESCRIPTION | 2 +- NAMESPACE | 21 +++ R/as-term-frame.R | 2 +- README.md | 359 +++++++++++++++++------------------- man/as_term.mcmc.Rd | 6 +- man/as_term.nlist.Rd | 4 +- man/as_term.nlists.Rd | 4 +- man/as_term_frame.Rd | 6 +- man/as_term_frame.nlist.Rd | 6 +- man/as_term_frame.nlists.Rd | 6 +- man/collapse_chains.mcmc.Rd | 4 +- 11 files changed, 209 insertions(+), 211 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index c81b954..41cc6c6 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -60,5 +60,5 @@ Config/testthat/edition: 3 Encoding: UTF-8 Language: en-US Roxygen: list(markdown = TRUE) -RoxygenNote: 7.2.3 +RoxygenNote: 7.3.2 VignetteBuilder: knitr diff --git a/NAMESPACE b/NAMESPACE index fa2b117..9e46fd0 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -152,9 +152,30 @@ importFrom(abind,abind) importFrom(coda,as.mcmc) importFrom(coda,as.mcmc.list) importFrom(coda,thin) +importFrom(extras,fill_all) +importFrom(extras,fill_na) +importFrom(extras,lower) +importFrom(extras,pvalue) +importFrom(extras,svalue) +importFrom(extras,upper) +importFrom(extras,zscore) +importFrom(generics,tidy) importFrom(purrr,transpose) importFrom(stats,aggregate) importFrom(stats,median) importFrom(term,as.term) importFrom(term,as_term) importFrom(term,complete_terms) +importFrom(universals,"pars<-") +importFrom(universals,bind_iterations) +importFrom(universals,collapse_chains) +importFrom(universals,estimates) +importFrom(universals,nchains) +importFrom(universals,niters) +importFrom(universals,npdims) +importFrom(universals,nsims) +importFrom(universals,nterms) +importFrom(universals,pars) +importFrom(universals,pdims) +importFrom(universals,set_pars) +importFrom(universals,split_chains) diff --git a/R/as-term-frame.R b/R/as-term-frame.R index 5b85e16..d8f8853 100644 --- a/R/as-term-frame.R +++ b/R/as-term-frame.R @@ -85,7 +85,7 @@ as_term_frame.nlists <- function(x, ...) { ))) } x <- mapply(as_term_frame_nlist_impl, x, - sample = 1:length(x), + sample = seq_along(x), SIMPLIFY = FALSE ) do.call("rbind", x) diff --git a/README.md b/README.md index 60acb96..06e498b 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,3 @@ - # nlist @@ -34,17 +33,13 @@ converted to `coda::mcmc` and `coda::mcmc.list` objects. To install the latest release from [CRAN](https://cran.r-project.org) -``` r -install.packages("nlist") -``` + install.packages("nlist") To install the developmental version from [GitHub](https://github.com/poissonconsulting/nlist) -``` r -# install.packages("remotes") -remotes::install_github("poissonconsulting/nlist") -``` + # install.packages("remotes") + remotes::install_github("poissonconsulting/nlist") ## Demonstration @@ -52,13 +47,11 @@ remotes::install_github("poissonconsulting/nlist") An numeric object is an integer or double vector, matrix or array. -``` r -library(nlist) -is.numeric(1L) -#> [1] TRUE -is.numeric(matrix(1:3)) -#> [1] TRUE -``` + library(nlist) + is.numeric(1L) + #> [1] TRUE + is.numeric(matrix(1:3)) + #> [1] TRUE ### `nlist` @@ -66,22 +59,20 @@ An `nlist` is an S3 class list of uniquely named numeric objects. It is straightforward to create an new `nlist` object. -``` r -library(nlist) - -nlist <- nlist(x = 1, y = matrix(1:9, 3)) -nlist -#> $x -#> [1] 1 -#> -#> $y -#> [,1] [,2] [,3] -#> [1,] 1 4 7 -#> [2,] 2 5 8 -#> [3,] 3 6 9 -#> -#> an nlist object with 2 numeric elements -``` + library(nlist) + + nlist <- nlist(x = 1, y = matrix(1:9, 3)) + nlist + #> $x + #> [1] 1 + #> + #> $y + #> [,1] [,2] [,3] + #> [1,] 1 4 7 + #> [2,] 2 5 8 + #> [3,] 3 6 9 + #> + #> an nlist object with 2 numeric elements ### `nlists` @@ -90,26 +81,24 @@ names, dimensionalities and typeofs. The nchains attribute is used to keep track of the number of chains. -``` r -nlists <- nlists( - nlist(x = 1, y = matrix(1:9, 3)), - nlist(x = -2, y = matrix(2:10, 3)), - nlist(x = 10, y = matrix(22:30, 3)), - nlist(x = -100, y = matrix(-2:-10, 3)) -) - -print(nlists) -#> $x -#> [1] -0.5 -#> -#> $y -#> [,1] [,2] [,3] -#> [1,] 1.5 4.5 7.5 -#> [2,] 2.5 5.5 8.5 -#> [3,] 3.5 6.5 9.5 -#> -#> an nlists object of 4 nlist objects each with 2 numeric elements -``` + nlists <- nlists( + nlist(x = 1, y = matrix(1:9, 3)), + nlist(x = -2, y = matrix(2:10, 3)), + nlist(x = 10, y = matrix(22:30, 3)), + nlist(x = -100, y = matrix(-2:-10, 3)) + ) + + print(nlists) + #> $x + #> [1] -0.5 + #> + #> $y + #> [,1] [,2] [,3] + #> [1,] 1.5 4.5 7.5 + #> [2,] 2.5 5.5 8.5 + #> [3,] 3.5 6.5 9.5 + #> + #> an nlists object of 4 nlist objects each with 2 numeric elements ### Coercion @@ -117,167 +106,155 @@ print(nlists) A data.frame can be coerced to an `nlist` object -``` r -data <- data.frame( - lgl = c(TRUE, NA), - dte = as.Date(c("2001-01-02", "2001-01-01")), - fac = factor(c("b", "a")) -) - -as_nlist(data) -#> $lgl -#> [1] 1 NA -#> -#> $dte -#> [1] 11324 11323 -#> -#> $fac -#> [1] 2 1 -#> -#> an nlist object with 3 numeric elements -``` + data <- data.frame( + lgl = c(TRUE, NA), + dte = as.Date(c("2001-01-02", "2001-01-01")), + fac = factor(c("b", "a")) + ) + + as_nlist(data) + #> $lgl + #> [1] 1 NA + #> + #> $dte + #> [1] 11324 11323 + #> + #> $fac + #> [1] 2 1 + #> + #> an nlist object with 3 numeric elements And an `nlist` objects can be converted to an `mcmc` or `term_frame` objects (and converted back again) -``` r -as_mcmc(nlist) -#> Markov Chain Monte Carlo (MCMC) output: -#> Start = 1 -#> End = 1 -#> Thinning interval = 1 -#> x y[1,1] y[2,1] y[3,1] y[1,2] y[2,2] y[3,2] y[1,3] y[2,3] y[3,3] -#> [1,] 1 1 2 3 4 5 6 7 8 9 -as_term_frame(nlist) -#> term value -#> 1 x 1 -#> 2 y[1,1] 1 -#> 3 y[2,1] 2 -#> 4 y[3,1] 3 -#> 5 y[1,2] 4 -#> 6 y[2,2] 5 -#> 7 y[3,2] 6 -#> 8 y[1,3] 7 -#> 9 y[2,3] 8 -#> 10 y[3,3] 9 -``` + as_mcmc(nlist) + #> Markov Chain Monte Carlo (MCMC) output: + #> Start = 1 + #> End = 1 + #> Thinning interval = 1 + #> x y[1,1] y[2,1] y[3,1] y[1,2] y[2,2] y[3,2] y[1,3] y[2,3] y[3,3] + #> [1,] 1 1 2 3 4 5 6 7 8 9 + as_term_frame(nlist) + #> term value + #> 1 x 1 + #> 2 y[1,1] 1 + #> 3 y[2,1] 2 + #> 4 y[3,1] 3 + #> 5 y[1,2] 4 + #> 6 y[2,2] 5 + #> 7 y[3,2] 6 + #> 8 y[1,3] 7 + #> 9 y[2,3] 8 + #> 10 y[3,3] 9 #### nlists The `estimates()` function can be used to aggregate an `nlists` object to an `nlist` object. -``` r -estimates(nlists, fun = mean) -#> $x -#> [1] -22.75 -#> -#> $y -#> [,1] [,2] [,3] -#> [1,] 5.75 7.25 8.75 -#> [2,] 6.25 7.75 9.25 -#> [3,] 6.75 8.25 9.75 -#> -#> an nlist object with 2 numeric elements -``` + estimates(nlists, fun = mean) + #> $x + #> [1] -22.75 + #> + #> $y + #> [,1] [,2] [,3] + #> [1,] 5.75 7.25 8.75 + #> [2,] 6.25 7.75 9.25 + #> [3,] 6.75 8.25 9.75 + #> + #> an nlist object with 2 numeric elements while the `tidy()` function treats the values as if they are MCMC samples and summarises the terms as a tidy tibble. -``` r -tidy(nlists, simplify = TRUE) -#> # A tibble: 10 × 5 -#> term estimate lower upper svalue -#> -#> 1 x -0.5 -92.6 9.32 0 -#> 2 y[1,1] 1.5 -1.77 20.5 0.737 -#> 3 y[2,1] 2.5 -2.62 21.5 0.737 -#> 4 y[3,1] 3.5 -3.47 22.5 0.737 -#> 5 y[1,2] 4.5 -4.32 23.5 0.737 -#> 6 y[2,2] 5.5 -5.17 24.5 0.737 -#> 7 y[3,2] 6.5 -6.02 25.5 0.737 -#> 8 y[1,3] 7.5 -6.87 26.5 0.737 -#> 9 y[2,3] 8.5 -7.72 27.5 0.737 -#> 10 y[3,3] 9.5 -8.57 28.5 0.737 -``` + tidy(nlists, simplify = TRUE) + #> # A tibble: 10 × 5 + #> term estimate lower upper svalue + #> + #> 1 x -0.5 -92.6 9.32 0 + #> 2 y[1,1] 1.5 -1.77 20.5 0.737 + #> 3 y[2,1] 2.5 -2.62 21.5 0.737 + #> 4 y[3,1] 3.5 -3.47 22.5 0.737 + #> 5 y[1,2] 4.5 -4.32 23.5 0.737 + #> 6 y[2,2] 5.5 -5.17 24.5 0.737 + #> 7 y[3,2] 6.5 -6.02 25.5 0.737 + #> 8 y[1,3] 7.5 -6.87 26.5 0.737 + #> 9 y[2,3] 8.5 -7.72 27.5 0.737 + #> 10 y[3,3] 9.5 -8.57 28.5 0.737 An `nlists` object can be converted to an `mcmc.list` object and a `term_frame`. -``` r -as_mcmc_list(nlists) -#> [[1]] -#> Markov Chain Monte Carlo (MCMC) output: -#> Start = 1 -#> End = 4 -#> Thinning interval = 1 -#> x y[1,1] y[2,1] y[3,1] y[1,2] y[2,2] y[3,2] y[1,3] y[2,3] y[3,3] -#> [1,] 1 1 2 3 4 5 6 7 8 9 -#> [2,] -2 2 3 4 5 6 7 8 9 10 -#> [3,] 10 22 23 24 25 26 27 28 29 30 -#> [4,] -100 -2 -3 -4 -5 -6 -7 -8 -9 -10 -#> -#> attr(,"class") -#> [1] "mcmc.list" -as_term_frame(nlists) -#> term sample value -#> 1 x 1 1 -#> 2 y[1,1] 1 1 -#> 3 y[2,1] 1 2 -#> 4 y[3,1] 1 3 -#> 5 y[1,2] 1 4 -#> 6 y[2,2] 1 5 -#> 7 y[3,2] 1 6 -#> 8 y[1,3] 1 7 -#> 9 y[2,3] 1 8 -#> 10 y[3,3] 1 9 -#> 11 x 2 -2 -#> 12 y[1,1] 2 2 -#> 13 y[2,1] 2 3 -#> 14 y[3,1] 2 4 -#> 15 y[1,2] 2 5 -#> 16 y[2,2] 2 6 -#> 17 y[3,2] 2 7 -#> 18 y[1,3] 2 8 -#> 19 y[2,3] 2 9 -#> 20 y[3,3] 2 10 -#> 21 x 3 10 -#> 22 y[1,1] 3 22 -#> 23 y[2,1] 3 23 -#> 24 y[3,1] 3 24 -#> 25 y[1,2] 3 25 -#> 26 y[2,2] 3 26 -#> 27 y[3,2] 3 27 -#> 28 y[1,3] 3 28 -#> 29 y[2,3] 3 29 -#> 30 y[3,3] 3 30 -#> 31 x 4 -100 -#> 32 y[1,1] 4 -2 -#> 33 y[2,1] 4 -3 -#> 34 y[3,1] 4 -4 -#> 35 y[1,2] 4 -5 -#> 36 y[2,2] 4 -6 -#> 37 y[3,2] 4 -7 -#> 38 y[1,3] 4 -8 -#> 39 y[2,3] 4 -9 -#> 40 y[3,3] 4 -10 -``` + as_mcmc_list(nlists) + #> [[1]] + #> Markov Chain Monte Carlo (MCMC) output: + #> Start = 1 + #> End = 4 + #> Thinning interval = 1 + #> x y[1,1] y[2,1] y[3,1] y[1,2] y[2,2] y[3,2] y[1,3] y[2,3] y[3,3] + #> [1,] 1 1 2 3 4 5 6 7 8 9 + #> [2,] -2 2 3 4 5 6 7 8 9 10 + #> [3,] 10 22 23 24 25 26 27 28 29 30 + #> [4,] -100 -2 -3 -4 -5 -6 -7 -8 -9 -10 + #> + #> attr(,"class") + #> [1] "mcmc.list" + as_term_frame(nlists) + #> term sample value + #> 1 x 1 1 + #> 2 y[1,1] 1 1 + #> 3 y[2,1] 1 2 + #> 4 y[3,1] 1 3 + #> 5 y[1,2] 1 4 + #> 6 y[2,2] 1 5 + #> 7 y[3,2] 1 6 + #> 8 y[1,3] 1 7 + #> 9 y[2,3] 1 8 + #> 10 y[3,3] 1 9 + #> 11 x 2 -2 + #> 12 y[1,1] 2 2 + #> 13 y[2,1] 2 3 + #> 14 y[3,1] 2 4 + #> 15 y[1,2] 2 5 + #> 16 y[2,2] 2 6 + #> 17 y[3,2] 2 7 + #> 18 y[1,3] 2 8 + #> 19 y[2,3] 2 9 + #> 20 y[3,3] 2 10 + #> 21 x 3 10 + #> 22 y[1,1] 3 22 + #> 23 y[2,1] 3 23 + #> 24 y[3,1] 3 24 + #> 25 y[1,2] 3 25 + #> 26 y[2,2] 3 26 + #> 27 y[3,2] 3 27 + #> 28 y[1,3] 3 28 + #> 29 y[2,3] 3 29 + #> 30 y[3,3] 3 30 + #> 31 x 4 -100 + #> 32 y[1,1] 4 -2 + #> 33 y[2,1] 4 -3 + #> 34 y[3,1] 4 -4 + #> 35 y[1,2] 4 -5 + #> 36 y[2,2] 4 -6 + #> 37 y[3,2] 4 -7 + #> 38 y[1,3] 4 -8 + #> 39 y[2,3] 4 -9 + #> 40 y[3,3] 4 -10 An `nlists` object can have its chains split or collapsed. -``` r -split_chains(nlists) -#> $x -#> [1] -0.5 -#> -#> $y -#> [,1] [,2] [,3] -#> [1,] 1.5 4.5 7.5 -#> [2,] 2.5 5.5 8.5 -#> [3,] 3.5 6.5 9.5 -#> -#> an nlists object with 2 chains of 2 nlist objects each with 2 numeric elements -``` + split_chains(nlists) + #> $x + #> [1] -0.5 + #> + #> $y + #> [,1] [,2] [,3] + #> [1,] 1.5 4.5 7.5 + #> [2,] 2.5 5.5 8.5 + #> [3,] 3.5 6.5 9.5 + #> + #> an nlists object with 2 chains of 2 nlist objects each with 2 numeric elements ## Contribution diff --git a/man/as_term.mcmc.Rd b/man/as_term.mcmc.Rd index 77f8184..a1b863d 100644 --- a/man/as_term.mcmc.Rd +++ b/man/as_term.mcmc.Rd @@ -19,10 +19,10 @@ as_term(as_mcmc(nlist(x = matrix(1:4, ncol = 2)))) } \seealso{ Other coerce term: -\code{\link{as_term.nlists}()}, \code{\link{as_term.nlist}()}, -\code{\link{as_term_frame.nlists}()}, +\code{\link{as_term.nlists}()}, +\code{\link{as_term_frame}()}, \code{\link{as_term_frame.nlist}()}, -\code{\link{as_term_frame}()} +\code{\link{as_term_frame.nlists}()} } \concept{coerce term} diff --git a/man/as_term.nlist.Rd b/man/as_term.nlist.Rd index 856db0e..2eafea7 100644 --- a/man/as_term.nlist.Rd +++ b/man/as_term.nlist.Rd @@ -21,8 +21,8 @@ as_term(nlist(x = matrix(1:4, ncol = 2))) Other coerce term: \code{\link{as_term.mcmc}()}, \code{\link{as_term.nlists}()}, -\code{\link{as_term_frame.nlists}()}, +\code{\link{as_term_frame}()}, \code{\link{as_term_frame.nlist}()}, -\code{\link{as_term_frame}()} +\code{\link{as_term_frame.nlists}()} } \concept{coerce term} diff --git a/man/as_term.nlists.Rd b/man/as_term.nlists.Rd index 36cb7d8..b8bceb9 100644 --- a/man/as_term.nlists.Rd +++ b/man/as_term.nlists.Rd @@ -21,8 +21,8 @@ as_term(nlists(nlist(x = matrix(1:4, ncol = 2)))) Other coerce term: \code{\link{as_term.mcmc}()}, \code{\link{as_term.nlist}()}, -\code{\link{as_term_frame.nlists}()}, +\code{\link{as_term_frame}()}, \code{\link{as_term_frame.nlist}()}, -\code{\link{as_term_frame}()} +\code{\link{as_term_frame.nlists}()} } \concept{coerce term} diff --git a/man/as_term_frame.Rd b/man/as_term_frame.Rd index 4d72eaf..52429a1 100644 --- a/man/as_term_frame.Rd +++ b/man/as_term_frame.Rd @@ -23,9 +23,9 @@ vector called samples. It includes the original nlist or nlists object. \seealso{ Other coerce term: \code{\link{as_term.mcmc}()}, -\code{\link{as_term.nlists}()}, \code{\link{as_term.nlist}()}, -\code{\link{as_term_frame.nlists}()}, -\code{\link{as_term_frame.nlist}()} +\code{\link{as_term.nlists}()}, +\code{\link{as_term_frame.nlist}()}, +\code{\link{as_term_frame.nlists}()} } \concept{coerce term} diff --git a/man/as_term_frame.nlist.Rd b/man/as_term_frame.nlist.Rd index 7110bdf..f5de310 100644 --- a/man/as_term_frame.nlist.Rd +++ b/man/as_term_frame.nlist.Rd @@ -24,9 +24,9 @@ as_term_frame(nlist(x = 1, y = 4:6)) \seealso{ Other coerce term: \code{\link{as_term.mcmc}()}, -\code{\link{as_term.nlists}()}, \code{\link{as_term.nlist}()}, -\code{\link{as_term_frame.nlists}()}, -\code{\link{as_term_frame}()} +\code{\link{as_term.nlists}()}, +\code{\link{as_term_frame}()}, +\code{\link{as_term_frame.nlists}()} } \concept{coerce term} diff --git a/man/as_term_frame.nlists.Rd b/man/as_term_frame.nlists.Rd index 0108988..b7e9791 100644 --- a/man/as_term_frame.nlists.Rd +++ b/man/as_term_frame.nlists.Rd @@ -27,9 +27,9 @@ as_term_frame(nlists( \seealso{ Other coerce term: \code{\link{as_term.mcmc}()}, -\code{\link{as_term.nlists}()}, \code{\link{as_term.nlist}()}, -\code{\link{as_term_frame.nlist}()}, -\code{\link{as_term_frame}()} +\code{\link{as_term.nlists}()}, +\code{\link{as_term_frame}()}, +\code{\link{as_term_frame.nlist}()} } \concept{coerce term} diff --git a/man/collapse_chains.mcmc.Rd b/man/collapse_chains.mcmc.Rd index 07b9a4c..6050ca6 100644 --- a/man/collapse_chains.mcmc.Rd +++ b/man/collapse_chains.mcmc.Rd @@ -25,7 +25,7 @@ collapse_chains(as_mcmc(nlist(x = 2))) } \seealso{ Other collapse: -\code{\link{collapse_chains.nlists}()}, -\code{\link{collapse_chains.nlist}()} +\code{\link{collapse_chains.nlist}()}, +\code{\link{collapse_chains.nlists}()} } \concept{collapse} From d164bcffad1c3aaa5cd4f2954090020857e53719 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Thu, 19 Sep 2024 07:04:16 -0600 Subject: [PATCH 04/10] extras package requires R >= 4.3 --- .github/workflows/R-CMD-check.yaml | 3 --- DESCRIPTION | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index ec753b1..d2f39c2 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -32,9 +32,6 @@ jobs: - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} - {os: ubuntu-latest, r: 'release'} - {os: ubuntu-latest, r: 'oldrel-1'} - - {os: ubuntu-latest, r: 'oldrel-2'} - - {os: ubuntu-latest, r: 'oldrel-3'} - - {os: ubuntu-latest, r: 'oldrel-4'} env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} diff --git a/DESCRIPTION b/DESCRIPTION index 41cc6c6..196ece1 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -34,7 +34,7 @@ License: MIT + file LICENSE URL: https://github.com/poissonconsulting/nlist BugReports: https://github.com/poissonconsulting/nlist/issues Depends: - R (>= 3.5) + R (>= 4.3) Imports: abind, chk, From d9474ab8ad29dc1fd86fb3e5773adc4b8622e21b Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Thu, 19 Sep 2024 07:09:41 -0600 Subject: [PATCH 05/10] needs R >= 4.3 --- .github/workflows/R-CMD-check.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index d2f39c2..b9cb923 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -26,8 +26,6 @@ jobs: - {os: macos-latest, r: 'release'} - {os: windows-latest, r: 'release'} - # use 4.0 or 4.1 to check with rtools40's older compiler - - {os: windows-latest, r: 'oldrel-4'} - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} - {os: ubuntu-latest, r: 'release'} From 34ca144d09a15f818769e8aaa86f870081303425 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Fri, 20 Sep 2024 15:35:43 -0600 Subject: [PATCH 06/10] reverted dependency back to R >= 4.0 --- .github/workflows/R-CMD-check.yaml | 5 +++++ DESCRIPTION | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index b9cb923..ec753b1 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -26,10 +26,15 @@ jobs: - {os: macos-latest, r: 'release'} - {os: windows-latest, r: 'release'} + # use 4.0 or 4.1 to check with rtools40's older compiler + - {os: windows-latest, r: 'oldrel-4'} - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} - {os: ubuntu-latest, r: 'release'} - {os: ubuntu-latest, r: 'oldrel-1'} + - {os: ubuntu-latest, r: 'oldrel-2'} + - {os: ubuntu-latest, r: 'oldrel-3'} + - {os: ubuntu-latest, r: 'oldrel-4'} env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} diff --git a/DESCRIPTION b/DESCRIPTION index 196ece1..f5cc4cf 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -34,7 +34,7 @@ License: MIT + file LICENSE URL: https://github.com/poissonconsulting/nlist BugReports: https://github.com/poissonconsulting/nlist/issues Depends: - R (>= 4.3) + R (>= 4.0) Imports: abind, chk, From eed0e0041afdd63083a6aff1ba430ce6b02af843 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Fri, 20 Sep 2024 15:44:24 -0600 Subject: [PATCH 07/10] removed old R-CMD-checks --- .github/workflows/R-CMD-check.yaml | 3 --- man/reexports.Rd | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index ec753b1..d2f39c2 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -32,9 +32,6 @@ jobs: - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} - {os: ubuntu-latest, r: 'release'} - {os: ubuntu-latest, r: 'oldrel-1'} - - {os: ubuntu-latest, r: 'oldrel-2'} - - {os: ubuntu-latest, r: 'oldrel-3'} - - {os: ubuntu-latest, r: 'oldrel-4'} env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} diff --git a/man/reexports.Rd b/man/reexports.Rd index 587722e..98a7ffc 100644 --- a/man/reexports.Rd +++ b/man/reexports.Rd @@ -50,7 +50,7 @@ below to see their documentation. \item{stats}{\code{\link[stats]{aggregate}}, \code{\link[stats]{median}}} - \item{term}{\code{\link[term]{as_term}}, \code{\link[term:as_term]{as.term}}, \code{\link[term]{complete_terms}}} + \item{term}{\code{\link[term:as_term]{as.term}}, \code{\link[term]{as_term}}, \code{\link[term]{complete_terms}}} \item{universals}{\code{\link[universals]{bind_iterations}}, \code{\link[universals]{collapse_chains}}, \code{\link[universals]{estimates}}, \code{\link[universals]{nchains}}, \code{\link[universals]{niters}}, \code{\link[universals]{npdims}}, \code{\link[universals]{nsims}}, \code{\link[universals]{nterms}}, \code{\link[universals]{pars}}, \code{\link[universals:set_pars]{pars<-}}, \code{\link[universals]{pdims}}, \code{\link[universals]{set_pars}}, \code{\link[universals]{split_chains}}} }} From 3056fe359ec0514571e3934a400bd6175fbdfc32 Mon Sep 17 00:00:00 2001 From: Joe Thorley Date: Mon, 23 Sep 2024 07:12:22 -0700 Subject: [PATCH 08/10] suppress build warning about exporting S3 method --- NAMESPACE | 1 + R/numericise.R | 2 ++ man/reexports.Rd | 2 +- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/NAMESPACE b/NAMESPACE index 9e46fd0..041f8f7 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -66,6 +66,7 @@ S3method(nterms,mcmc) S3method(nterms,mcmc.list) S3method(nterms,nlist) S3method(nterms,nlists) +S3method(numericise,list) S3method(pars,mcmc) S3method(pars,mcmc.list) S3method(pars,nlist) diff --git a/R/numericise.R b/R/numericise.R index 2e66399..b1554e9 100644 --- a/R/numericise.R +++ b/R/numericise.R @@ -1,3 +1,5 @@ + +#' @export numericise.list <- function(x, ...) lapply(x, numericise) numericise.nlist <- function(x, ...) x diff --git a/man/reexports.Rd b/man/reexports.Rd index 98a7ffc..587722e 100644 --- a/man/reexports.Rd +++ b/man/reexports.Rd @@ -50,7 +50,7 @@ below to see their documentation. \item{stats}{\code{\link[stats]{aggregate}}, \code{\link[stats]{median}}} - \item{term}{\code{\link[term:as_term]{as.term}}, \code{\link[term]{as_term}}, \code{\link[term]{complete_terms}}} + \item{term}{\code{\link[term]{as_term}}, \code{\link[term:as_term]{as.term}}, \code{\link[term]{complete_terms}}} \item{universals}{\code{\link[universals]{bind_iterations}}, \code{\link[universals]{collapse_chains}}, \code{\link[universals]{estimates}}, \code{\link[universals]{nchains}}, \code{\link[universals]{niters}}, \code{\link[universals]{npdims}}, \code{\link[universals]{nsims}}, \code{\link[universals]{nterms}}, \code{\link[universals]{pars}}, \code{\link[universals:set_pars]{pars<-}}, \code{\link[universals]{pdims}}, \code{\link[universals]{set_pars}}, \code{\link[universals]{split_chains}}} }} From a754b2145667d8c0f60b403f0bac7d46efb61c83 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Mon, 23 Sep 2024 09:14:59 -0600 Subject: [PATCH 09/10] removed R-CMD-check note Co-authored-by: Joe Thorley --- .github/workflows/R-CMD-check.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index d2f39c2..013a740 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -1,9 +1,5 @@ # 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 -# -# NOTE: This workflow is overkill for most R packages and -# check-standard.yaml is likely a better choice. -# usethis::use_github_action("check-standard") will install it. on: push: branches: [main, master] From be327ac3a4fa2d45e72ca9bf55bc37f26de98e04 Mon Sep 17 00:00:00 2001 From: Duncan Kennedy Date: Mon, 23 Sep 2024 09:17:06 -0600 Subject: [PATCH 10/10] styler --- R/as-nlist.R | 9 ++- R/as-nlists.R | 3 +- R/as-term-frame.R | 4 +- R/bind-iterations.R | 24 +++---- R/chk.R | 4 +- R/complete-terms.R | 8 +-- R/extras.R | 3 +- R/is.R | 4 +- R/numericise.R | 1 - R/pars.R | 10 ++- R/set-pars.R | 4 +- R/split-chains.R | 2 +- R/subset.R | 22 +++--- R/tidy.R | 19 +++-- tests/testthat/test-as-mcmc-list.R | 9 ++- tests/testthat/test-as-mcmc.R | 12 ++-- tests/testthat/test-as-nlist.R | 10 ++- tests/testthat/test-as-nlists.R | 2 +- tests/testthat/test-c.R | 17 ++--- tests/testthat/test-complete-terms.R | 8 ++- tests/testthat/test-split-chains.R | 3 +- tests/testthat/test-subset.R | 88 ++++++++++++++--------- tests/testthat/test-tidy.R | 40 ++++++----- vignettes/nlist-objects-and-coercions.Rmd | 20 +++--- 24 files changed, 186 insertions(+), 140 deletions(-) diff --git a/R/as-nlist.R b/R/as-nlist.R index 5d54057..9444354 100644 --- a/R/as-nlist.R +++ b/R/as-nlist.R @@ -17,8 +17,8 @@ as_nlist <- function(x, ...) { #' @export as.nlist <- function(x, ...) { deprecate_warn("0.1.1", - what = "nlist::as.nlist()", - with = "nlist::as_nlist()" + what = "nlist::as.nlist()", + with = "nlist::as_nlist()" ) UseMethod("as_nlist") } @@ -31,7 +31,7 @@ as_nlist.numeric <- function(x, ...) { chk_not_any_na(names(x)) chk_unique(names(x)) chk_unused(...) - + if (!length(x)) { return(nlist()) } @@ -70,7 +70,7 @@ as_nlist.data.frame <- function(x, ...) as_nlist(as.list(x)) #' @export as_nlist.mcmc <- function(x, ...) { chk_unused(...) - if(!identical(nrow(x), 1L)) abort_chk("`x` must have one iteration.") + if (!identical(nrow(x), 1L)) abort_chk("`x` must have one iteration.") x <- complete_terms(x) @@ -89,4 +89,3 @@ as_nlist.mcmc.list <- function(x, ...) { #' @export as_nlist.nlist <- function(x, ...) x - diff --git a/R/as-nlists.R b/R/as-nlists.R index b92dabf..eab0f48 100644 --- a/R/as-nlists.R +++ b/R/as-nlists.R @@ -45,8 +45,9 @@ as_nlists.mcmc.list <- function(x, ...) { nchains <- nchains(x) x <- as_mcmc(x) x <- as_nlists(x) - if(nchains != 1L) + if (nchains != 1L) { attr(x, "nchains") <- nchains + } x } diff --git a/R/as-term-frame.R b/R/as-term-frame.R index d8f8853..7add00c 100644 --- a/R/as-term-frame.R +++ b/R/as-term-frame.R @@ -15,7 +15,7 @@ as_term_frame <- function(x, ...) { #' Coerce nlist Object to Data Frame #' -#' Coerces an nlist object to a data.frame with an term column +#' Coerces an nlist object to a data.frame with an term column #' and a value column. #' #' @export @@ -62,7 +62,7 @@ as_term_frame_nlist_impl <- function(x, sample = NULL) { #' Coerce nlists Object to Data Frame #' -#' Coerces an nlists object to a data.frame with a term, sample +#' Coerces an nlists object to a data.frame with a term, sample #' and value column. #' #' @export diff --git a/R/bind-iterations.R b/R/bind-iterations.R index 2efac3e..8962d16 100644 --- a/R/bind-iterations.R +++ b/R/bind-iterations.R @@ -7,22 +7,22 @@ universals::bind_iterations #' bind_iterations(as_mcmc(nlist(x = 1)), as_mcmc(nlist(x = 3))) bind_iterations.mcmc <- function(x, x2, ...) { chk_s3_class(x2, "mcmc") - + x <- sort(x) x2 <- sort(x2) - + if (!identical(pars(x), pars(x2))) { abort_chk("`x` and `x2` must have the same parameters") } - + if (!identical(pdims(x), pdims(x2))) { abort_chk("`x` and `x2` must have the same parameter dimensions") } - + if (!identical(nchains(x), nchains(x2))) { abort_chk("`x` and `x2` must have the same number of chains") } - + x <- abind(x, x2, along = 1) as.mcmc(x) } @@ -32,27 +32,27 @@ bind_iterations.mcmc <- function(x, x2, ...) { #' @examples #' bind_iterations(as_mcmc_list(nlist(x = 1)), as_mcmc_list(nlist(x = 3))) bind_iterations.mcmc.list <- function(x, x2, ...) { - if(!(vld_s3_class(x2, "mcmc.list") || vld_s3_class(x2, "mcmc"))) { + if (!(vld_s3_class(x2, "mcmc.list") || vld_s3_class(x2, "mcmc"))) { if (!vld_all_identical(lapply(x, lapply, dims))) { abort_chk("`x2` must inherit from S3 class 'mcmc.list' or 'mcmc'.") - } + } } - + x <- sort(x) x2 <- sort(x2) - + if (!identical(pars(x), pars(x2))) { abort_chk("`x` and `x2` must have the same parameters") } - + if (!identical(pdims(x), pdims(x2))) { abort_chk("`x` and `x2` must have the same parameter dimensions") } - + if (!identical(nchains(x), nchains(x2))) { abort_chk("`x` and `x2` must have the same number of chains") } - + x <- mapply(x, x2, FUN = bind_iterations, SIMPLIFY = FALSE) set_class(x, "mcmc.list") } diff --git a/R/chk.R b/R/chk.R index 8370d33..e97f1bb 100644 --- a/R/chk.R +++ b/R/chk.R @@ -22,8 +22,8 @@ chk_nlist <- function(x, x_name = NULL) { chk_named(x, x_name = x_name) x_name_names <- backtick_chk(p0("names(", unbacktick_chk(x_name), ")")) chk_pars(names(x), x_name = x_name_names) - chk_not_any_na(names(x), x_name = x_name_names) - chk_unique(names(x), x_name = x_name_names) + chk_not_any_na(names(x), x_name = x_name_names) + chk_unique(names(x), x_name = x_name_names) chk_all(x, chk_numeric, x_name = x_name) } diff --git a/R/complete-terms.R b/R/complete-terms.R index 139321a..102d038 100644 --- a/R/complete-terms.R +++ b/R/complete-terms.R @@ -1,5 +1,5 @@ #' @importFrom term complete_terms -#' @export +#' @export term::complete_terms #' Complete Terms @@ -21,13 +21,13 @@ term::complete_terms complete_terms.mcmc <- function(x, silent = FALSE, ...) { chk_flag(silent) chk_unused(...) - + if (!silent && anyNA(colnames(x))) { wrn("terms with missing values have been dropped") } x <- as.matrix(x) - x <- x[,!is.na(colnames(x)), drop = FALSE] + x <- x[, !is.na(colnames(x)), drop = FALSE] colnames(x) <- as.character(as_term(colnames(x), repair = TRUE)) if (!silent && anyNA(colnames(x))) wrn("invalid terms have been dropped") x <- x[, !is.na(colnames(x)), drop = FALSE] @@ -39,7 +39,7 @@ complete_terms.mcmc <- function(x, silent = FALSE, ...) { wrn("inconsistent terms have been dropped") } x <- x[, consistent, drop = FALSE] - + if (!ncol(x)) { return(coda::as.mcmc(x)) } diff --git a/R/extras.R b/R/extras.R index bc98714..bf96b94 100644 --- a/R/extras.R +++ b/R/extras.R @@ -3,7 +3,8 @@ as_list_unnamed_default <- function(x, ...) { x <- as.list(x) names <- names(x) attributes(x) <- NULL - if(!is.null(names)) + if (!is.null(names)) { names(x) <- names + } x } diff --git a/R/is.R b/R/is.R index fa19ddc..52ae0ea 100644 --- a/R/is.R +++ b/R/is.R @@ -5,7 +5,7 @@ #' #' @inheritParams params #' @return A flag indicating whether x is a numeric object or inherits from S3 class nlist or nlists. -#' +#' #' @export #' #' @examples @@ -17,7 +17,7 @@ is_numeric <- function(x) { } #' @describeIn is_numeric Is nlist -#' +#' #' @export #' #' @examples diff --git a/R/numericise.R b/R/numericise.R index b1554e9..8ce1af5 100644 --- a/R/numericise.R +++ b/R/numericise.R @@ -1,4 +1,3 @@ - #' @export numericise.list <- function(x, ...) lapply(x, numericise) diff --git a/R/pars.R b/R/pars.R index b9a4232..63ddb28 100644 --- a/R/pars.R +++ b/R/pars.R @@ -13,7 +13,9 @@ pars.mcmc <- function(x, scalar = NULL, terms = FALSE, ...) { deprecate_warn("0.2.1", "nlist::pars(terms =)", details = "If `terms = TRUE` use `terms::pars_terms(as_term(x)) otherwise replace `pars(x, terms = FALSE)` with `pars(x)`.", id = "pars_terms") } x <- as_term(x) - if(terms) return(pars_terms(x, scalar = scalar)) + if (terms) { + return(pars_terms(x, scalar = scalar)) + } pars(x, scalar = scalar) } @@ -24,13 +26,15 @@ pars.mcmc.list <- function(x, scalar = NULL, terms = FALSE, ...) { if (!is.null(scalar)) chk_flag(scalar) chk_flag(terms) chk_unused(...) - + if (!missing(terms)) { deprecate_warn("0.2.1", "nlist::pars(terms =)", details = "If `terms = TRUE` use `terms::pars_terms(as_term(x)) otherwise replace `pars(x, terms = FALSE)` with `pars(x)`.", id = "pars_terms") } x <- x[[1]] x <- as_term(x) - if(terms) return(pars_terms(x, scalar = scalar)) + if (terms) { + return(pars_terms(x, scalar = scalar)) + } pars(x, scalar = scalar) } diff --git a/R/set-pars.R b/R/set-pars.R index c93d4f8..177b7a7 100644 --- a/R/set-pars.R +++ b/R/set-pars.R @@ -25,7 +25,7 @@ set_pars.mcmc.list <- function(x, value, ...) { #' #' @export #' @examples -#' nlist <- nlist(x = 1, y = 3:4) +#' nlist <- nlist(x = 1, y = 3:4) #' pars(nlist) <- c("a", "b") #' nlist #' set_pars(nlist, c("z", "c1")) @@ -52,7 +52,7 @@ set_pars.nlist <- function(x, value, ...) { #' @inherit universals::set_pars #' #' @export -#' @examples +#' @examples #' nlists <- nlists(nlist(x = 2), nlist(x = 3)) #' pars(nlists) <- "a" #' nlists diff --git a/R/split-chains.R b/R/split-chains.R index c1dc021..59191ae 100644 --- a/R/split-chains.R +++ b/R/split-chains.R @@ -3,7 +3,7 @@ universals::split_chains #' @inherit universals::split_chains #' @export -#' @examples +#' @examples #' nlists <- nlists(nlist(x = c(2, 9)), nlist(x = c(1, 7))) #' nchains(nlists) #' nchains(split_chains(nlists)) diff --git a/R/subset.R b/R/subset.R index 1be75c8..453d945 100644 --- a/R/subset.R +++ b/R/subset.R @@ -12,18 +12,18 @@ #' @examples #' mcmc <- as_mcmc(nlist(beta = 1:2, theta = 1)) #' subset(mcmc, pars = "beta") -#' subset(mcmc, iters = c(1L,1L)) +#' subset(mcmc, iters = c(1L, 1L)) subset.mcmc <- function(x, iters = NULL, pars = NULL, iterations = NULL, parameters = NULL, ...) { if (!missing(iterations)) { deprecate_warn("0.2.1", "subset(iterations = )", "subset(iters = )", - id = "subset_iterations" + id = "subset_iterations" ) iters <- iterations } if (!missing(parameters)) { deprecate_warn("0.2.1", "subset(parameters = )", "subset(pars = )", - id = "subset_parameters" + id = "subset_parameters" ) pars <- parameters } @@ -38,7 +38,7 @@ subset.mcmc <- function(x, iters = NULL, pars = NULL, chk_subset(pars, pars(x)) } chk_unused(...) - + if (!is.null(pars)) x <- x[, pars_terms(as_term(x)) %in% pars, drop = FALSE] if (!is.null(iters)) x <- x[iters, , drop = FALSE] set_class(x, "mcmc") @@ -56,21 +56,23 @@ subset.mcmc <- function(x, iters = NULL, pars = NULL, #' @export #' #' @examples -#' mcmc.list <- as_mcmc_list(nlists(nlist(beta = 1:2, theta = 1), -#' nlist(beta = 3:4, theta = -1))) +#' mcmc.list <- as_mcmc_list(nlists( +#' nlist(beta = 1:2, theta = 1), +#' nlist(beta = 3:4, theta = -1) +#' )) #' subset(mcmc.list, pars = "beta") -#' subset(mcmc.list, iters = c(1L,1L)) +#' subset(mcmc.list, iters = c(1L, 1L)) subset.mcmc.list <- function(x, chains = NULL, iters = NULL, pars = NULL, iterations = NULL, parameters = NULL, ...) { if (!missing(iterations)) { deprecate_warn("0.2.1", "subset(iterations = )", "subset(iters = )", - id = "subset_iterations" + id = "subset_iterations" ) iters <- iterations } if (!missing(parameters)) { deprecate_warn("0.2.1", "subset(parameters = )", "subset(pars = )", - id = "subset_parameters" + id = "subset_parameters" ) pars <- parameters } @@ -80,7 +82,7 @@ subset.mcmc.list <- function(x, chains = NULL, iters = NULL, pars = NULL, chk_range(chains, c(1L, nchains(x))) } chk_unused(...) - + if (!is.null(chains)) { x <- x[chains] } diff --git a/R/tidy.R b/R/tidy.R index 8e276ca..3aff06d 100644 --- a/R/tidy.R +++ b/R/tidy.R @@ -30,8 +30,8 @@ tidy.mcmc.list <- function(x, simplify = FALSE, ...) { tidy.nlists <- function(x, simplify = FALSE, ...) { chk_flag(simplify) chk_unused(...) - - if(!simplify) { + + if (!simplify) { lifecycle::deprecate_warn("0.3.1", "tidy(simplify = 'must be TRUE')") } if (!length(x) || !length(x[[1]])) { @@ -42,19 +42,18 @@ tidy.nlists <- function(x, simplify = FALSE, ...) { lower <- numeric(0) upper <- numeric(0) svalue <- numeric(0) - - if(simplify) { + + if (simplify) { return(tibble::tibble( term = term, estimate = estimate, lower = lower, upper = upper, svalue = svalue )) - } + } return(tibble::tibble( term = term, estimate = estimate, - sd = sd, zscore = zscore, + sd = sd, zscore = zscore, lower = lower, upper = upper, svalue = svalue )) - } else { estimate <- unlist(estimates(x, median)) term <- as_term(names(estimate)) @@ -65,14 +64,14 @@ tidy.nlists <- function(x, simplify = FALSE, ...) { upper <- unname(unlist(estimates(x, upper))) svalue <- unname(unlist(estimates(x, svalue))) } - if(simplify) { - return( tibble::tibble( + if (simplify) { + return(tibble::tibble( term = term, estimate = estimate, lower = lower, upper = upper, svalue = svalue )) } - + tibble::tibble( term = term, estimate = estimate, sd = sd, zscore = zscore, lower = lower, diff --git a/tests/testthat/test-as-mcmc-list.R b/tests/testthat/test-as-mcmc-list.R index 6a9a84a..5a0985c 100644 --- a/tests/testthat/test-as-mcmc-list.R +++ b/tests/testthat/test-as-mcmc-list.R @@ -150,7 +150,7 @@ test_that("as.mcmc.list.nlist", { NULL, c("x", "y") ), mcpar = c(1, 1, 1), class = "mcmc")), class = "mcmc.list") ) - + expect_identical( coda::as.mcmc.list(nlist::nlist(x = 1, y = matrix(1:4, 2))), structure(list(structure(c(1, 1, 2, 3, 4), .Dim = c(1L, 5L), .Dimnames = list( @@ -179,7 +179,7 @@ test_that("as.mcmc.list.nlists", { NULL, NULL ), mcpar = c(1, 2, 1), class = "mcmc")), class = "mcmc.list") ) - + expect_identical( coda::as.mcmc.list(nlists(nlist(x = 1))), structure(list(structure(1, .Dim = c(1L, 1L), .Dimnames = list( @@ -201,7 +201,7 @@ test_that("as.mcmc.list.nlists", { ) ), mcpar = c(1, 1, 1), class = "mcmc")), class = "mcmc.list") ) - + expect_identical( coda::as.mcmc.list(nlists( nlist(x = matrix(1:6, 2)), @@ -218,7 +218,7 @@ test_that("as.mcmc.list.nlists", { 2, 1 ), class = "mcmc")), class = "mcmc.list") ) - + nlists <- nlists(nlist(x = matrix(1:6, 2)), nlist(x = matrix(3:8, 2))) attr(nlists, "nchains") <- 2L expect_identical( @@ -237,4 +237,3 @@ test_that("as.mcmc.list.nlists", { )), mcpar = c(1, 1, 1), class = "mcmc")), class = "mcmc.list") ) }) - diff --git a/tests/testthat/test-as-mcmc.R b/tests/testthat/test-as-mcmc.R index 4a98c89..c75a22f 100644 --- a/tests/testthat/test-as-mcmc.R +++ b/tests/testthat/test-as-mcmc.R @@ -1,6 +1,8 @@ test_that("as_mcmc.mcmc.list", { - expect_identical(as_mcmc(as_mcmc_list(nlists(nlist(x = 2), nlist(x = 3)))), - as_mcmc(nlists(nlist(x = 2), nlist(x = 3)))) + expect_identical( + as_mcmc(as_mcmc_list(nlists(nlist(x = 2), nlist(x = 3)))), + as_mcmc(nlists(nlist(x = 2), nlist(x = 3))) + ) }) test_that("as_mcmc.nlist", { @@ -147,7 +149,7 @@ test_that("as.mcmc.nlist", { "y" )), mcpar = c(1, 1, 1), class = "mcmc") ) - + expect_identical( as.mcmc(nlist::nlist(x = 1, y = matrix(1:4, 2))), structure(c(1, 1, 2, 3, 4), .Dim = c(1L, 5L), .Dimnames = list( @@ -178,7 +180,7 @@ test_that("as.mcmc.nlists", { NULL ), mcpar = c(1, 2, 1), class = "mcmc") ) - + expect_identical( as.mcmc(nlists(nlist(x = 1))), structure(1, .Dim = c(1L, 1L), .Dimnames = list(NULL, "x"), mcpar = c( @@ -203,7 +205,7 @@ test_that("as.mcmc.nlists", { 1, 1 ), class = "mcmc") ) - + expect_identical( as.mcmc(nlists( nlist(x = matrix(1:6, 2)), diff --git a/tests/testthat/test-as-nlist.R b/tests/testthat/test-as-nlist.R index 3df1419..0b016b0 100644 --- a/tests/testthat/test-as-nlist.R +++ b/tests/testthat/test-as-nlist.R @@ -34,10 +34,14 @@ test_that("as_nlist.mcmc.list", { expect_identical(as_nlist(as_mcmc_list(nlist(x = 1))), nlist(x = 1)) expect_identical(as_nlist(as_mcmc_list(nlist(x = 1, y = 2))), nlist(x = 1, y = 2)) expect_identical(as_nlist(as_mcmc_list(nlist(x = matrix(1:12, nrow = 3)))), nlist(x = matrix(1:12, nrow = 3))) - expect_identical(as_nlist(as_mcmc_list(nlists(nlist(x = matrix(1:12, nrow = 3))))), - nlist(x = matrix(1:12, nrow = 3))) + expect_identical( + as_nlist(as_mcmc_list(nlists(nlist(x = matrix(1:12, nrow = 3))))), + nlist(x = matrix(1:12, nrow = 3)) + ) expect_error(as_nlist(as_mcmc_list(nlists(nlist(x = 1), nlist(x = 2)))), - "`x` must have one iteration.", class = "chk_error") + "`x` must have one iteration.", + class = "chk_error" + ) }) test_that("as_nlist.nlist", { diff --git a/tests/testthat/test-as-nlists.R b/tests/testthat/test-as-nlists.R index e32156f..614d254 100644 --- a/tests/testthat/test-as-nlists.R +++ b/tests/testthat/test-as-nlists.R @@ -37,7 +37,7 @@ test_that("as_nlists.mcmc.list 2 chains", { nlist(x = 3, y = matrix(4:1, 2)) ) nlists <- split_chains(nlists) - + expect_equal(as_nlists(as_mcmc_list(nlists)), nlists) expect_equal(nchains(as_nlists(as_mcmc_list(nlists))), 2L) }) diff --git a/tests/testthat/test-c.R b/tests/testthat/test-c.R index 3593231..db108f1 100644 --- a/tests/testthat/test-c.R +++ b/tests/testthat/test-c.R @@ -10,8 +10,8 @@ test_that("c.nlist", { expect_identical(c(nlist(), nlist(x = 1)), nlist(x = 1)) expect_error( c(nlist(x = 1), nlist(x = 1)), - "^nlist objects must have distinctly named numeric elements in order to be concatenated[.]$" - , class = "chk_error" + "^nlist objects must have distinctly named numeric elements in order to be concatenated[.]$", + class = "chk_error" ) }) @@ -29,12 +29,13 @@ test_that("c.nlists", { "^All elements of ... must inherit from S3 class 'nlists'[.]", class = "chk_error" ) - expect_error(c( - nlists(nlist(x = 1)), - nlists(nlist(y = 1)) - ), - "^nlist elements of [.][.][.] must have matching names[.]$", - class = "chk_error" + expect_error( + c( + nlists(nlist(x = 1)), + nlists(nlist(y = 1)) + ), + "^nlist elements of [.][.][.] must have matching names[.]$", + class = "chk_error" ) }) diff --git a/tests/testthat/test-complete-terms.R b/tests/testthat/test-complete-terms.R index f51bb76..e1abed9 100644 --- a/tests/testthat/test-complete-terms.R +++ b/tests/testthat/test-complete-terms.R @@ -4,13 +4,15 @@ test_that("complete_terms 1 iteration", { mcmc[, "beta[2,2]"] <- NA expect_identical(complete_terms(mcmc), mcmc) mcmc2 <- mcmc - mcmc2 <- mcmc2[, -4,drop = FALSE] + mcmc2 <- mcmc2[, -4, drop = FALSE] expect_identical(complete_terms(mcmc2), mcmc) }) test_that("complete_terms 2 iterations", { - mcmc <- as_mcmc(nlists(nlist(beta = matrix(1:4, nrow = 2)), - nlist(beta = matrix(1:4, nrow = 2)))) + mcmc <- as_mcmc(nlists( + nlist(beta = matrix(1:4, nrow = 2)), + nlist(beta = matrix(1:4, nrow = 2)) + )) expect_identical(complete_terms(mcmc), mcmc) mcmc[, "beta[2,2]"] <- NA expect_identical(complete_terms(mcmc), mcmc) diff --git a/tests/testthat/test-split-chains.R b/tests/testthat/test-split-chains.R index 0decfb6..bb5d38d 100644 --- a/tests/testthat/test-split-chains.R +++ b/tests/testthat/test-split-chains.R @@ -9,7 +9,8 @@ test_that("split_chains nlists", { test_that("split_chains nlists error", { nlists <- nlists(nlist(x = matrix(1:6, 2))) expect_error(split_chains(nlists), "^`x` must have at least two iterations[.]$", - class = "chk_error") + class = "chk_error" + ) }) test_that("split_chains nlists extra iters", { diff --git a/tests/testthat/test-subset.R b/tests/testthat/test-subset.R index 8e4f76d..d221c40 100644 --- a/tests/testthat/test-subset.R +++ b/tests/testthat/test-subset.R @@ -1,47 +1,69 @@ test_that("subset.mcmc", { - expect_equal(subset(as_mcmc(nlist(beta = 1:2, theta = 1))), - as_mcmc(nlist(beta = 1:2, theta = 1))) - expect_equal(subset(as_mcmc(nlist(beta = 1:2, theta = 1)), pars = "beta"), - as_mcmc(nlist(beta = 1:2))) - + expect_equal( + subset(as_mcmc(nlist(beta = 1:2, theta = 1))), + as_mcmc(nlist(beta = 1:2, theta = 1)) + ) + expect_equal( + subset(as_mcmc(nlist(beta = 1:2, theta = 1)), pars = "beta"), + as_mcmc(nlist(beta = 1:2)) + ) + expect_equal(subset(as_mcmc(nlists(nlist(beta = 1:2), nlist(beta = 3:4))), iters = 1), - as_mcmc(nlists(nlist(beta = 1:2))), - ignore_attr = TRUE) + as_mcmc(nlists(nlist(beta = 1:2))), + ignore_attr = TRUE + ) + + expect_equal(subset(as_mcmc(nlists(nlist(beta = 1:2), nlist(beta = 3:4))), iters = c(1, 1)), + as_mcmc(nlists(nlist(beta = 1:2), nlist(beta = 1:2))), + ignore_attr = TRUE + ) - expect_equal(subset(as_mcmc(nlists(nlist(beta = 1:2), nlist(beta = 3:4))), iters = c(1,1)), - as_mcmc(nlists(nlist(beta = 1:2), nlist(beta = 1:2))), - ignore_attr = TRUE) - skip("allow mcmc objects to be reodered by par") - expect_equal(subset(as_mcmc(nlist(beta = 1:2, theta = 1)), pars = c("theta", "beta")), - as_mcmc(nlist(theta = 1:2, beta = 1))) + expect_equal( + subset(as_mcmc(nlist(beta = 1:2, theta = 1)), pars = c("theta", "beta")), + as_mcmc(nlist(theta = 1:2, beta = 1)) + ) }) test_that("subset.mcmc.list", { - - mcmc.list <- as_mcmc_list(nlists(nlist(beta = 1:2, theta = 1), - nlist(beta = 3:4, theta = -1))) - expect_equal(subset(mcmc.list, pars = "beta"), - as_mcmc_list(nlists(nlist(beta = 1:2), - nlist(beta = 3:4)))) - expect_equal(subset(mcmc.list, iters = c(1L,1L)), - as_mcmc_list(nlists(nlist(beta = 1:2, theta = 1), - nlist(beta = 1:2, theta = 1))), - ignore_attr = TRUE) - - expect_equal(subset(as_mcmc_list(nlist(beta = 1:2, theta = 1)), pars = "beta"), - as_mcmc_list(nlist(beta = 1:2))) + mcmc.list <- as_mcmc_list(nlists( + nlist(beta = 1:2, theta = 1), + nlist(beta = 3:4, theta = -1) + )) + expect_equal( + subset(mcmc.list, pars = "beta"), + as_mcmc_list(nlists( + nlist(beta = 1:2), + nlist(beta = 3:4) + )) + ) + expect_equal(subset(mcmc.list, iters = c(1L, 1L)), + as_mcmc_list(nlists( + nlist(beta = 1:2, theta = 1), + nlist(beta = 1:2, theta = 1) + )), + ignore_attr = TRUE + ) + + expect_equal( + subset(as_mcmc_list(nlist(beta = 1:2, theta = 1)), pars = "beta"), + as_mcmc_list(nlist(beta = 1:2)) + ) expect_equal(subset(as_mcmc_list(nlists(nlist(beta = 1:2), nlist(beta = 3:4))), iters = 1), - as_mcmc_list(nlists(nlist(beta = 1:2))), - ignore_attr = TRUE) - + as_mcmc_list(nlists(nlist(beta = 1:2))), + ignore_attr = TRUE + ) + nlists <- nlists(nlist(x = 1), nlist(x = 2)) nlists <- split_chains(nlists) - expect_equal(subset(as_mcmc_list(nlists), chains = 1:2), - as_mcmc_list(nlists)) + expect_equal( + subset(as_mcmc_list(nlists), chains = 1:2), + as_mcmc_list(nlists) + ) expect_equal(subset(as_mcmc_list(nlists), chains = 2), - as_mcmc_list(subset(nlists, chains = 2)), - ignore_attr = TRUE) + as_mcmc_list(subset(nlists, chains = 2)), + ignore_attr = TRUE + ) }) test_that("subset.nlist", { diff --git a/tests/testthat/test-tidy.R b/tests/testthat/test-tidy.R index e98b9be..d476771 100644 --- a/tests/testthat/test-tidy.R +++ b/tests/testthat/test-tidy.R @@ -1,8 +1,8 @@ test_that("tidy.nlists", { rlang::local_options(lifecycle_verbosity = "quiet") - + lifecycle::expect_deprecated(tidy(nlists())) - + expect_identical(tidy(nlists()), structure(list( term = structure(character(0), class = c( "term", @@ -83,25 +83,31 @@ test_that("tidy.nlists", { ) expect_identical( tidy(nlists(nlist(x = 2:4)), simplify = TRUE), - tibble::tibble(term = term(x = 3), estimate = c(2, 3, 4) - , lower = c( - 2, - 3, 4 - ), upper = c(2, 3, 4), svalue = c(1, 1, 1)) + tibble::tibble( + term = term(x = 3), estimate = c(2, 3, 4), + lower = c( + 2, + 3, 4 + ), upper = c(2, 3, 4), svalue = c(1, 1, 1) + ) ) expect_identical( tidy(nlists(nlist(y = 1, s = 1:2)), simplify = TRUE), - tibble::tibble(term = term("y", s = 2), estimate = c(1, 1, 2), - lower = c( - 1, - 1, 2 - ), upper = c(1, 1, 2), svalue = c(1, 1, 1)) + tibble::tibble( + term = term("y", s = 2), estimate = c(1, 1, 2), + lower = c( + 1, + 1, 2 + ), upper = c(1, 1, 2), svalue = c(1, 1, 1) + ) ) - expect_equal(tidy(nlists(nlist(x = 1, y = 1:2), nlist(x = 1, y = 3:4)), simplify = TRUE), tibble::tibble(term = term("x" = 1, y = 2), estimate = c(1, 2, 3), - lower = c(1, 1.05, 2.05), upper = c(1, 2.95, 3.95), svalue = c( - 1.58496250072116, - 1.58496250072116, 1.58496250072116 - ))) + expect_equal(tidy(nlists(nlist(x = 1, y = 1:2), nlist(x = 1, y = 3:4)), simplify = TRUE), tibble::tibble( + term = term("x" = 1, y = 2), estimate = c(1, 2, 3), + lower = c(1, 1.05, 2.05), upper = c(1, 2.95, 3.95), svalue = c( + 1.58496250072116, + 1.58496250072116, 1.58496250072116 + ) + )) }) test_that("tidy.mcmc", { diff --git a/vignettes/nlist-objects-and-coercions.Rmd b/vignettes/nlist-objects-and-coercions.Rmd index 0da5836..d8e4e91 100644 --- a/vignettes/nlist-objects-and-coercions.Rmd +++ b/vignettes/nlist-objects-and-coercions.Rmd @@ -25,9 +25,11 @@ The central object is the `nlist` object which is a list of uniquely named numer `nlist` objects are the raw data inputs for analytic engines such as JAGS, STAN and TMB. ```{r} -nlist <- nlist(x = 1:2, - y = matrix(c(4:1), nrow = 2), - z = 5.1) +nlist <- nlist( + x = 1:2, + y = matrix(c(4:1), nrow = 2), + z = 5.1 +) print(nlist) str(nlist) ``` @@ -42,9 +44,11 @@ An `nlists` object is a list of `nlist` objects of S3 class `nlists`. nlists <- nlists( nlist, nlist, - nlist(x = 2:3, - y = matrix(c(5:8), nrow = 2), - z = 8) + nlist( + x = 2:3, + y = matrix(c(5:8), nrow = 2), + z = 8 + ) ) print(nlists) str(nlists) @@ -81,7 +85,7 @@ A vector can be coerced back to an nlist object if an nlist object is available ```{r} list <- unlist(nlist) list[1] <- 100 -list["z"] <- -999 +list["z"] <- -999 relist_nlist(list, nlist) ``` @@ -90,7 +94,7 @@ relist_nlist(list, nlist) A `data.frame` of numeric vectors can be coerced to an `nlist` object. ```{r} -as_nlist(data.frame(x = 1:2, y = c(3,5))) +as_nlist(data.frame(x = 1:2, y = c(3, 5))) ``` ## term frame