Skip to content

Commit

Permalink
updated dpcys
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewphamilton committed Apr 22, 2024
1 parent 2682dfa commit 573fccf
Show file tree
Hide file tree
Showing 24 changed files with 140 additions and 65 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ jobs:
permissions:
contents: write
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

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

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

Expand All @@ -32,6 +34,14 @@ jobs:
with:
use-public-rspm: true

# Addresses issue with incompatibility between libcurl4-gnutls-dev and libcurl4-openssl-dev
# Below fix is a customisation of approach outlined in https://github.com/r-hub/sysreqsdb/issues/77#issuecomment-620025428
- name: Install libraptor on Linux
if: runner.os == 'Linux'
run: |
sudo add-apt-repository ppa:cran/librdf
sudo apt update
# Addresses issue with incompatibility between libcurl4-gnutls-dev and libcurl4-openssl-dev
# Below fix is a customisation of approach outlined in https://github.com/r-hub/sysreqsdb/issues/77#issuecomment-620025428
- name: Install libraptor on Linux
Expand All @@ -51,7 +61,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
Expand Down
13 changes: 9 additions & 4 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Description: Modules from the readyforwhatsnext youth mental health
package has been made available as part of the process of testing and
documenting the package. If you have any questions, please contact
the authors ([email protected]).
License: GPL-3 + file LICENSE
License: GPL-3
URL: https://ready4-dev.github.io/TTU/, https://github.com/ready4-dev/TTU,
https://ready4-dev.github.io/ready4/
Encoding: UTF-8
Expand All @@ -30,8 +30,10 @@ Suggests:
caret,
knitr,
knitrBootstrap,
pkgload,
rmarkdown,
testthat
testthat,
youthvars (>= 0.0.0.9125)
VignetteBuilder: knitr
Imports:
dplyr,
Expand All @@ -50,7 +52,8 @@ Imports:
utils
Depends:
R (>= 2.10),
specific
scorz (>= 0.0.0.9065),
specific (>= 0.0.0.9108)
LazyData: true
Collate:
'C4_TTUSynopsis.R'
Expand All @@ -75,4 +78,6 @@ Collate:
Remotes:
ready4-dev/ready4show,
ready4-dev/ready4use,
ready4-dev/specific
ready4-dev/specific,
ready4-dev/youthvars,
ready4-dev/scorz
15 changes: 0 additions & 15 deletions LICENSE

This file was deleted.

4 changes: 4 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Generated by roxygen2: do not edit by hand

export("%>%")
export(":=")
export(.data)
export(TTUProject)
export(TTUReports)
export(TTUSynopsis)
Expand Down Expand Up @@ -49,6 +51,8 @@ importFrom(ready4,write_fls_to_dv)
importFrom(ready4,write_with_consent)
importFrom(ready4show,make_rmd_fl_nms_ls)
importFrom(ready4use,Ready4useRepos)
importFrom(rlang,":=")
importFrom(rlang,.data)
importFrom(rlang,exec)
importFrom(stringr,str_locate)
importFrom(stringr,str_replace_all)
Expand Down
6 changes: 3 additions & 3 deletions R/C4_TTUSynopsis.R
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,17 @@
#' @slot d_YouthvarsProfile (an instance of the YouthvarsProfile class)
#' @slot e_Ready4useRepos (an instance of the Ready4useRepos class)
#' @slot abstract_args_ls Abstract arguments (a list)
#' @slot authors_r3 Authors (a ready4 S3)
#' @slot authors_r3 Authors (a ready4 submodule)
#' @slot background_1L_chr Background (a character vector of length one)
#' @slot coi_1L_chr Conflict of interest (a character vector of length one)
#' @slot conclusion_1L_chr Conclusion (a character vector of length one)
#' @slot correspondences_r3 Correspondences (a ready4 S3)
#' @slot correspondences_r3 Correspondences (a ready4 submodule)
#' @slot digits_int Digits (an integer vector)
#' @slot ethics_1L_chr Ethics (a character vector of length one)
#' @slot fl_nm_1L_chr File name (a character vector of length one)
#' @slot figures_in_body_lgl Figures in body (a logical vector)
#' @slot funding_1L_chr Funding (a character vector of length one)
#' @slot institutes_r3 Institutes (a ready4 S3)
#' @slot institutes_r3 Institutes (a ready4 submodule)
#' @slot interval_chr Interval (a character vector)
#' @slot keywords_chr Keywords (a character vector)
#' @slot outp_formats_chr Output formats (a character vector)
Expand Down
2 changes: 1 addition & 1 deletion R/fn_get.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#' Get package citation
#' @description get_pkg_citation() is a Get function that retrieves a pre-existing data object from memory, local file system or online repository. Specifically, this function implements an algorithm to get package citation. Function argument pkg_nm_1L_chr specifies the where to look for the required object. The function returns Citation (a character vector of length one).
#' @description get_pkg_citation() is a Get function that extracts data from an object. Specifically, this function implements an algorithm to get package citation. The function returns Citation (a character vector of length one).
#' @param pkg_nm_1L_chr Package name (a character vector of length one)
#' @return Citation (a character vector of length one)
#' @rdname get_pkg_citation
Expand Down
36 changes: 32 additions & 4 deletions R/imp_fns.R
Original file line number Diff line number Diff line change
@@ -1,23 +1,51 @@
#' Pipe operator
#'
#' Implements: https://github.com/sckott/analogsea/issues/32
#' and https://github.com/rstudio/ggvis/blob/master/R/pipe.R.
#' Import of [magrittr::%>%()]. See magrittr package documentation for detailed description.
#'
#' @importFrom magrittr %>%
#' @name %>%
#' @rdname pipe
#' @export
#' @param lhs,rhs An object and a function to apply to it
#' @keywords internal
#' @returns The type of return from this function depends on the left hand side and right hand side arguments supplied to it. In principle, any type of returned object is feasible.
#' @seealso [magrittr::%>%()]
NULL

#' Deprecated function
#'
#' Import of deprecated function as recommended in lifecycle package documentation.
#' Import of [lifecycle::deprecated()]. See lifecycle package documentation for detailed description.
#'
#' @importFrom lifecycle deprecated
#' @name deprecated
#' @rdname deprecated
#' @export
#' @keywords internal
#' @returns Does not return a value as the function is used to signal that a function argument has been deprecated.
#' @seealso [lifecycle::deprecated()]
NULL

#' Non standard evaluation assignment function
#'
#' Import of := function, implementing [rlang::dyn-dots()]. See rlang package documentation for detailed description.
#'
#' @importFrom rlang :=
#' @name :=
#' @rdname nseequals
#' @export
#' @keywords internal
#' @returns Does not return a value. Used to implement non standard evaluation within a dynamic dots context.
#' @seealso [rlang::dyn-dots()]
NULL

#' Dot Data function
#'
#' Import of [rlang::.data()]. See rlang package documentation for detailed description.
#'
#' @importFrom rlang .data
#' @name .data
#' @rdname dotdata
#' @export
#' @keywords internal
#' @returns Does not return a value. A pronoun for use in data-masked functions.
#' @seealso [rlang::.data()]
NULL
2 changes: 1 addition & 1 deletion R/mthd_author.R
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#' @param what_1L_chr What (a character vector of length one), Default: 'NA'
#' @param x_labels_chr X labels (a character vector), Default: character(0)
#' @param ... Additional arguments
#' @return NULL
#' @return No return value, called for side effects.
#' @rdname author-methods
#' @aliases author,TTUReports-method
#' @export
Expand Down
4 changes: 2 additions & 2 deletions R/mthd_exhibit.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#'
#' Exhibit features of a dataset by printing them to the R console
#' Exhibit features of model module data by printing them to the R console
#' @name exhibit-TTUProject
#' @description exhibit method applied to TTUProject
#' @param x An object of class TTUProject
Expand All @@ -16,7 +16,7 @@
#' @param variables_chr Variables (a character vector), Default: character(0)
#' @param what_1L_chr What (a character vector of length one), Default: 'predictors'
#' @param ... Additional arguments
#' @return NULL
#' @return No return value, called for side effects.
#' @rdname exhibit-methods
#' @aliases exhibit,TTUProject-method
#' @export
Expand Down
2 changes: 1 addition & 1 deletion R/mthd_renew.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#'
#' Renew values in a dataset
#' Renew (update) values
#' @name renew-TTUProject
#' @description renew method applied to TTUProject
#' @param x An object of class TTUProject
Expand Down
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,14 @@
[![ready4](https://img.shields.io/badge/ready4-modelling-indigo?style=flat&labelColor=black&logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABHNCSVQICAgIfAhkiAAAAAFzUkdCAK7OHOkAAAAEZ0FNQQAAsY8L/GEFAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAIXRFWHRDcmVhdGlvbiBUaW1lADIwMjI6MDM6MDcgMTY6MTM6NTPZeG5UAAABa0lEQVQ4T4WT607CQBCFpyUi3qIR0eAfNfCi/vENfEgENIAIlcJ6vr1oLaZOerJzdst0zpklc49nznqHZs6ZfWwDem1xM1sqXwtXkb8rL4SuOLEoLXPPXWfD01Dg9dPsrTQbngQ+EZ+LDyIfiy/FHyIfFZbbTslWKOOqxx/uWBPSfp07FahGlqlNfWGqL9HNfBO+CAfwdO55WS8g4MFML834sfJVA9e7vwsg50aGohncdmRojV9XeL+jArRNmZxVSJ4Acj3NHqARdyeFJqC2KJiCfKE9zsfxnNYTl5TcCtmNMcwY/ZXf+3wdzzVza2vj4iCaq3d1R/bvwVSH6IPjNIUHx0FSNZA7WquDqOVb35+eiO8h7Oe+vRfp0a3yGtFMDuiAIg2R20YaVwJ3Hj+4kehO/J/I7VJ/jHtpvBP6mrHnR4EzdyQ0xI8HhM8jUiChxVpDK3iVuadzx43yRdI4E2d0gNtX74TCs419AR8YEST/cHPBAAAAAElFTkSuQmCC)](https://www.ready4-dev.com/docs/software/libraries/types/module/)
[![R-CMD-check](https://github.com/ready4-dev/TTU/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/ready4-dev/TTU/actions/workflows/R-CMD-check.yaml)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.5646593.svg)](https://doi.org/10.5281/zenodo.5646593)
[![CRAN status](https://www.r-pkg.org/badges/version/TTU)](https://CRAN.R-project.org/package=TTU)
<!-- badges: end -->

Modules from the ready4 youth mental health economic model
(https://www.ready4-dev.com/docs/model/) that can be used to develop,
assess, report and share utility mapping models. Outputs produced
through use of TTU package modules are designed to integrate with
health economic models developed with the ready4 framework
Modules from the readyforwhatsnext youth mental health
economic model (https://readyforwhatsnext.org/) that can be used to
develop, assess, report and share utility mapping models. Outputs
produced through use of TTU package modules are designed to integrate
with health economic models developed with the ready4 framework
(https://www.ready4-dev.com/). This development version of the TTU
package has been made available as part of the process of testing and
documenting the package. If you have any questions, please contact
Expand Down
2 changes: 1 addition & 1 deletion _pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ home:
href: https://github.com/ready4-dev/TTU/releases/download/Documentation_0.0/TTU_User.pdf
- text: Manual - Developer (PDF)
href: https://github.com/ready4-dev/TTU/releases/download/Documentation_0.0/TTU_Developer.pdf
- text: Framework & Model
- text: Model
href: https://ready4-dev.github.io/ready4/
development:
mode: auto
Expand Down
16 changes: 8 additions & 8 deletions data-raw/DATASET.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ready4fun::write_fn_type_dirs()
fns_env_ls <- ready4fun::read_fns(c("data-raw/fns/","data-raw/mthds/"),
fns_env = new.env(parent = globalenv()))
x <- ready4fun::make_pkg_desc_ls(pkg_title_1L_chr = "Implement Transfer to Utility Mapping Algorithms",
pkg_desc_1L_chr = "Modules from the ready4 youth mental health economic model (https://www.ready4-dev.com/docs/model/) that can be used to develop, assess, report and share utility mapping models.
pkg_desc_1L_chr = "Modules from the readyforwhatsnext youth mental health economic model (https://readyforwhatsnext.org/) that can be used to develop, assess, report and share utility mapping models.
Outputs produced through use of TTU package modules are designed to integrate with health economic models developed with the ready4 framework (https://www.ready4-dev.com/).
This development version of the TTU package has been made available as part of the process of testing and documenting the package.
If you have any questions, please contact the authors ([email protected]).",
Expand All @@ -27,10 +27,10 @@ x <- ready4fun::make_pkg_desc_ls(pkg_title_1L_chr = "Implement Transfer to Utili
depends_chr = "specific"),
build_ignore_ls = ready4fun::make_build_ignore_ls(file_nms_chr = c("initial_setup.R")),
check_type_1L_chr = "ready4",
copyright_holders_chr = "Orygen",
copyright_holders_chr = "Matthew Hamilton and Orygen",
custom_dmt_ls = ready4fun::make_custom_dmt_ls(),##
dev_pkgs_chr = c("cmdstanr",
"ready4",#"ready4fun",
#"ready4",#"ready4fun",
"ready4use","ready4show",
#"youthvars","scorz",
"specific"),
Expand Down Expand Up @@ -189,7 +189,7 @@ z <- ready4pack::make_pt_ready4pack_manifest(x,
pkg_ds_ls_ls = datasets_ls) %>%
ready4pack::ready4pack_manifest()
z <- ready4::author(z)
ready4::write_extra_pkgs_to_actions(consent_1L_chr = "Y")
ready4::write_extra_pkgs_to_actions(path_to_dir_1L_chr = ".github/workflows", consent_1L_chr = "Y")
usethis::use_dev_package("youthvars",
type = "Suggests",#D?
remote = "ready4-dev/youthvars")
Expand All @@ -200,10 +200,10 @@ usethis::use_dev_package("specific",
type = "Depends",
remote = "ready4-dev/specific")
write_to_edit_workflow("pkgdown.yaml", consent_1L_chr = "Y") # In other packages, run for "test-coverage.yaml" as well.
readLines("_pkgdown.yml") %>%
stringr::str_replace_all(" - text: Model", " - text: Framework & Model") %>%
writeLines(con = "_pkgdown.yml")
devtools::build_vignettes()
write_to_tidy_pkg(z$x_ready4fun_manifest, build_vignettes_1L_lgl = TRUE,
clean_license_1L_lgl = TRUE, consent_1L_chr = "Y",
examples_chr = character(0),
suggest_chr = "pkgload")
# usethis::use_package("readr")
# MANUAL DELETION OF TRAILING INCLUDE
# usethis::use_dev_package("ready4",
Expand Down
8 changes: 4 additions & 4 deletions inst/CITATION
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
citHeader(paste0("To cite ",meta$Package," in publications use:"))

citEntry(
entry = "Manual",
bibentry(
bibtype = "Manual",
doi = "10.5281/zenodo.5646593",
title = paste0(meta$Package,": ",meta$Title),
author = c(person("Caroline Gao <[email protected]> [aut]", "(<https://orcid.org/0000-0002-0987-2759>)"), person("Matthew Hamilton <[email protected]> [aut, cre, fnd]", "(<https://orcid.org/0000-0001-7407-9194>)")),
year = "2023",
year = "2024",
note = sprintf("R package version %s", meta$Version),
url = "https://ready4-dev.github.io/TTU/",
textVersion = paste("Caroline Gao <[email protected]> [aut] (<https://orcid.org/0000-0002-0987-2759>), Matthew Hamilton <[email protected]> [aut, cre and fnd] (<https://orcid.org/0000-0001-7407-9194>) ",
"(2023).",
"(2024).",
paste0(meta$Package,": ",meta$Title,
"."),
paste0(sprintf("Version %s", meta$Version),"."),
Expand Down
5 changes: 2 additions & 3 deletions man/TTU-package.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions man/TTUSynopsis-class.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions man/author-methods.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 7 additions & 1 deletion man/deprecated.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 573fccf

Please sign in to comment.