Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vignettes #43

Merged
merged 11 commits into from
Oct 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
6 changes: 6 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,9 @@
^doc$
^Meta$
^data-raw$
^README\.qmd$
^README_files$
^mwana\.Rproj$
^vignettes/plausibility_files$
^vignettes/prevalence_files$
^vignettes/sample_size_files$
10 changes: 9 additions & 1 deletion .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,13 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: quarto-dev/quarto-actions/setup@v2
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
version: ${{ matrix.config.quarto || 'release' }}
tinytex: true

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

- uses: r-lib/actions/setup-r@v2
Expand All @@ -41,7 +48,8 @@ jobs:

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::rcmdcheck
# install the package itself as we register vignette engine
extra-packages: any::rcmdcheck, local::.
needs: check

- uses: r-lib/actions/check-r-package@v2
Expand Down
53 changes: 53 additions & 0 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# 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]
release:
types: [published]
workflow_dispatch:

name: pkgdown.yaml

permissions: read-all

jobs:
pkgdown:
runs-on: ubuntu-latest
# Only restrict concurrency for non-PR jobs
concurrency:
group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: write
steps:
- uses: actions/checkout@v4

- name: Set up Quarto
uses: quarto-dev/quarto-actions/setup@v2

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

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

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::.
needs: website

- name: Build site
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
shell: Rscript {0}

- name: Deploy to GitHub pages 🚀
if: github.event_name != 'pull_request'
uses: JamesIves/[email protected]
with:
clean: false
branch: gh-pages
folder: docs
79 changes: 0 additions & 79 deletions .github/workflows/pr-commands.yaml

This file was deleted.

1 change: 1 addition & 0 deletions .github/workflows/test-coverage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

steps:
- uses: actions/checkout@v4
Expand Down
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,11 @@ inst/doc
docs
/doc/
/Meta/

/README_files/

/vignettes/plausibility_files/
/vignettes/prevalence_files/
/vignettes/sample_size_files/

/.quarto/
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ Description: A streamlined and comprehensive implementation of the Standardized
handling large multiple datasets.
License: GPL (>= 3)
URL: https://github.com/nutriverse/mwana, https://nutriverse.io/mwana
BugReports: https://github.com/nutriverse/mwana/issues
Imports:
dplyr (>= 1.1.4),
lubridate,
Expand All @@ -29,6 +28,7 @@ Imports:
Suggests:
knitr,
rmarkdown,
quarto,
spelling,
testthat (>= 3.0.0)
Config/testthat/edition: 3
Expand All @@ -39,4 +39,4 @@ RoxygenNote: 7.3.2
Depends:
R (>= 4.1)
LazyData: true
VignetteBuilder: knitr
VignetteBuilder: quarto
5 changes: 3 additions & 2 deletions R/age.R
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ compute_age_in_months <- function (surv_date, birth_date) {


#'
#' Wrangle child's age
#' Process child's age
#'
#' @description
#' Wrangle child's age for downstream analysis. This includes calculating age
#' Process child's age for downstream analysis. This includes calculating age
#' in months based on the date of data collection and child's date of birth and
#' setting to `NA` the age values that are less than 6.0 and greater than or equal
#' to 60.0 months old.
Expand All @@ -66,6 +66,7 @@ compute_age_in_months <- function (surv_date, birth_date) {
#' @examples
#'
#' ## A sample data ----
#'
#' df <- data.frame(
#' survy_date = as.Date(c(
#' "2023-01-01", "2023-01-01", "2023-01-01", "2023-01-01", "2023-01-01")),
Expand Down
158 changes: 0 additions & 158 deletions README.Rmd

This file was deleted.

Loading
Loading