Skip to content

Commit 4d89788

Browse files
committed
Merge branch 'develop'
2 parents 2b8eb20 + 6141974 commit 4d89788

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+838
-189
lines changed

.github/workflows/R_CMD_check_Hades.yaml

+39-56
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ jobs:
2020
fail-fast: false
2121
matrix:
2222
config:
23-
- {os: windows-latest, r: 'release'} # Does not appear to have Java 32-bit, hence the --no-multiarch
23+
- {os: windows-latest, r: 'release'}
2424
- {os: macOS-latest, r: 'release'}
2525
- {os: ubuntu-20.04, r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}
26-
# - {os: ubuntu-20.04, r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}
2726

2827
env:
28+
GITHUB_PAT: ${{ secrets.GH_TOKEN }}
2929
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
3030
RSPM: ${{ matrix.config.rspm }}
3131
CDM5_ORACLE_CDM_SCHEMA: ${{ secrets.CDM5_ORACLE_CDM_SCHEMA }}
@@ -43,75 +43,51 @@ jobs:
4343
CDM5_SQL_SERVER_PASSWORD: ${{ secrets.CDM5_SQL_SERVER_PASSWORD }}
4444
CDM5_SQL_SERVER_SERVER: ${{ secrets.CDM5_SQL_SERVER_SERVER }}
4545
CDM5_SQL_SERVER_USER: ${{ secrets.CDM5_SQL_SERVER_USER }}
46+
CDM5_REDSHIFT_CDM_SCHEMA: ${{ secrets.CDM5_REDSHIFT_CDM_SCHEMA }}
47+
CDM5_REDSHIFT_OHDSI_SCHEMA: ${{ secrets.CDM5_REDSHIFT_OHDSI_SCHEMA }}
48+
CDM5_REDSHIFT_PASSWORD: ${{ secrets.CDM5_REDSHIFT_PASSWORD }}
49+
CDM5_REDSHIFT_SERVER: ${{ secrets.CDM5_REDSHIFT_SERVER }}
50+
CDM5_REDSHIFT_USER: ${{ secrets.CDM5_REDSHIFT_USER }}
51+
CDM5_SPARK_USER: ${{ secrets.CDM5_SPARK_USER }}
52+
CDM5_SPARK_PASSWORD: ${{ secrets.CDM5_SPARK_PASSWORD }}
53+
CDM5_SPARK_CONNECTION_STRING: ${{ secrets.CDM5_SPARK_CONNECTION_STRING }}
54+
WEBAPI_TEST_WEBAPI_URL: ${{ secrets.WEBAPI_TEST_WEBAPI_URL }}
55+
WEBAPI_TEST_SECURE_WEBAPI_URL: ${{ secrets.WEBAPI_TEST_SECURE_WEBAPI_URL }}
56+
WEBAPI_TEST_ADMIN_USER_NAME: ${{ secrets.WEBAPI_TEST_ADMIN_USER_NAME }}
57+
WEBAPI_TEST_ADMIN_USER_PASSWORD: ${{ secrets.WEBAPI_TEST_ADMIN_USER_PASSWORD }}
4658

4759
steps:
48-
- uses: actions/checkout@v2
60+
- uses: actions/checkout@v3
4961

50-
- uses: r-lib/actions/setup-r@v1
62+
- uses: r-lib/actions/setup-r@v2
5163
with:
5264
r-version: ${{ matrix.config.r }}
5365

54-
- uses: r-lib/actions/setup-tinytex@v1
66+
- uses: r-lib/actions/setup-tinytex@v2
5567

56-
- uses: r-lib/actions/setup-pandoc@v1
68+
- uses: r-lib/actions/setup-pandoc@v2
5769

58-
- name: Query dependencies
59-
run: |
60-
install.packages('remotes')
61-
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2)
62-
writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version")
63-
shell: Rscript {0}
64-
65-
- name: Cache R packages
66-
if: runner.os != 'Windows'
67-
uses: actions/cache@v2
68-
with:
69-
path: ${{ env.R_LIBS_USER }}
70-
key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-${{ hashFiles('.github/depends.Rds') }}
71-
restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-
72-
73-
- name: Install system dependencies
70+
- name: Install system requirements
7471
if: runner.os == 'Linux'
7572
run: |
73+
sudo apt-get install -y libssh-dev
74+
Rscript -e 'install.packages("remotes")'
7675
while read -r cmd
7776
do
7877
eval sudo $cmd
7978
done < <(Rscript -e 'writeLines(remotes::system_requirements("ubuntu", "20.04"))')
8079
81-
- name: Install libssh
82-
if: runner.os == 'Linux'
83-
run: |
84-
sudo apt-get install libssh-dev
85-
86-
- name: Install dependencies
87-
run: |
88-
remotes::install_deps(dependencies = TRUE, INSTALL_opts=c("--no-multiarch"))
89-
remotes::install_cran("rcmdcheck")
90-
shell: Rscript {0}
91-
92-
- name: Install covr
93-
if: runner.os == 'macOS'
94-
run: |
95-
remotes::install_cran("covr")
96-
shell: Rscript {0}
97-
98-
- name: Remove check folder if exists
99-
if: runner.os == 'macOS'
100-
run: unlink("check", recursive = TRUE)
101-
shell: Rscript {0}
102-
103-
- name: Check
104-
env:
105-
_R_CHECK_CRAN_INCOMING_REMOTE_: false
106-
run: rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran", "--no-multiarch"), error_on = "warning", check_dir = "check")
107-
shell: Rscript {0}
80+
- uses: r-lib/actions/setup-r-dependencies@v2
81+
with:
82+
extra-packages: any::rcmdcheck
83+
needs: check
10884

109-
- name: Upload check results
110-
if: failure()
111-
uses: actions/upload-artifact@v2
85+
- uses: r-lib/actions/check-r-package@v2
11286
with:
113-
name: ${{ runner.os }}-r${{ matrix.config.r }}-results
114-
path: check
87+
args: 'c("--no-manual", "--as-cran")'
88+
build_args: 'c("--compact-vignettes=both")'
89+
error-on: '"warning"'
90+
check-dir: '"check"'
11591

11692
- name: Upload source package
11793
if: success() && runner.os == 'macOS' && github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
@@ -120,6 +96,12 @@ jobs:
12096
name: package_tarball
12197
path: check/*.tar.gz
12298

99+
- name: Install covr
100+
if: runner.os == 'macOS'
101+
run: |
102+
install.packages("covr")
103+
shell: Rscript {0}
104+
123105
- name: Test coverage
124106
if: runner.os == 'macOS'
125107
run: covr::codecov()
@@ -137,7 +119,7 @@ jobs:
137119

138120
steps:
139121

140-
- uses: actions/checkout@v2
122+
- uses: actions/checkout@v3
141123
with:
142124
fetch-depth: 0
143125

@@ -163,7 +145,7 @@ jobs:
163145
draft: false
164146
prerelease: false
165147

166-
- uses: r-lib/actions/setup-r@v1
148+
- uses: r-lib/actions/setup-r@v2
167149
if: ${{ env.new_version != '' }}
168150

169151
- name: Install drat
@@ -192,3 +174,4 @@ jobs:
192174
if: ${{ env.new_version != '' }}
193175
run: |
194176
curl --data "build=true" -X POST https://registry.hub.docker.com/u/ohdsi/broadsea-methodslibrary/trigger/f0b51cec-4027-4781-9383-4b38b42dd4f5/
177+

Cyclops.Rproj

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Version: 1.0
22

3-
RestoreWorkspace: Default
4-
SaveWorkspace: Default
3+
RestoreWorkspace: No
4+
SaveWorkspace: No
55
AlwaysSaveHistory: Default
66

77
EnableCodeIndexing: Yes

DESCRIPTION

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: Cyclops
22
Type: Package
33
Title: Cyclic Coordinate Descent for Logistic, Poisson and Survival Analysis
4-
Version: 3.3.1
4+
Version: 3.3.1.999
55
Authors@R: c(
66
person("Marc A.", "Suchard", email = "[email protected]", role = c("aut","cre")),
77
person("Martijn J.", "Schuemie", role = "aut"),
@@ -30,7 +30,7 @@ Biarch: true
3030
URL: https://github.com/ohdsi/cyclops
3131
BugReports: https://github.com/ohdsi/cyclops/issues
3232
Depends:
33-
R (>= 3.1.0)
33+
R (>= 3.5.0)
3434
Imports:
3535
rlang,
3636
Matrix,
@@ -41,7 +41,6 @@ Imports:
4141
survival,
4242
bit64
4343
LinkingTo: Rcpp,
44-
BH (>= 1.51.0),
4544
RcppEigen (>= 0.3.2)
4645
Suggests:
4746
testthat,

NAMESPACE

+4
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,15 @@ S3method(survfit,cyclopsFit)
1313
S3method(vcov,cyclopsFit)
1414
export(Multitype)
1515
export(convertToCyclopsData)
16+
export(convertToTimeVaryingCoef)
1617
export(coverage)
1718
export(createAutoGridCrossValidationControl)
1819
export(createControl)
1920
export(createCyclopsData)
2021
export(createNonSeparablePrior)
2122
export(createParameterizedPrior)
2223
export(createPrior)
24+
export(createWeightBasedSearchControl)
2325
export(finalizeSqlCyclopsData)
2426
export(fitCyclopsModel)
2527
export(fitCyclopsSimulation)
@@ -39,6 +41,7 @@ export(meanLinearPredictor)
3941
export(mse)
4042
export(readCyclopsData)
4143
export(simulateCyclopsData)
44+
export(splitTime)
4245
import(Matrix)
4346
import(Rcpp)
4447
import(dplyr)
@@ -71,5 +74,6 @@ importFrom(stats,terms)
7174
importFrom(stats,time)
7275
importFrom(stats,vcov)
7376
importFrom(survival,Surv)
77+
importFrom(survival,survSplit)
7478
importFrom(survival,survfit)
7579
useDynLib(Cyclops, .registration = TRUE)

NEWS.md

+23-4
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,42 @@
1+
Cyclops v3.4.0
2+
==============
3+
4+
Changes:
5+
6+
1. remove dependence on `BH`
7+
2. improvements on adaptive likelihood profiling
8+
3. add `auto` option to `cvRepetitions`
9+
4. bumped explicit C++11 requirement up to R v4.1
10+
5. removed deprecated use of `dbplyr:::$.tbl_lazy`
11+
a. breaking change in `dbplyr v2.4.0`
12+
113
Cyclops v3.3.1
214
==============
315

416
Changes:
517

6-
1. fix uninitialized value in detected in computeAsymptoticPrecisionMatrix(); value was priorType
7-
2. fix memory leak caused by call to ::Rf_error()
18+
1. fix uninitialized value in detected in `computeAsymptoticPrecisionMatrix()`; value was priorType
19+
2. fix memory leak caused by call to `::Rf_error()`
820
3. fix line-endings on Makevar on windows
921

1022
Cyclops v3.3.0
1123
==============
1224

13-
Changes:
14-
1525
1. bump for R 4.2
1626
2. fix CRAN warnings
1727
a. used `minValues`
1828
3. fix CRAN notes
1929
a. remove explicit dependence on C++11 (except for R <= 4.0)
2030

31+
Cyclops v3.2.1
32+
==============
33+
34+
Changes:
35+
36+
1. fix small memory leak caused by direct call to '::Rf_error()'
37+
2. disable JVM calls on CRAN due to uninitialized memory in Java JVM
38+
39+
2140
Cyclops v3.2.0
2241
==============
2342

R/Cyclops-package.R

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#' @keywords internal
2+
"_PACKAGE"
3+
4+
## usethis namespace: start
5+
## usethis namespace: end
6+
NULL

R/DataManagement.R

+2-2
Original file line numberDiff line numberDiff line change
@@ -634,8 +634,8 @@ reduce <- function(object, covariates, groupBy, power = 1) {
634634
#' \code{appendSqlCyclopsData} appends data to an OHDSI data object.
635635
#'
636636
#' @details Append data using two tables. The outcomes table is dense and contains ... The covariates table is sparse and contains ...
637-
#' All entries in the outcome table must be sorted in increasing order by {oStratumId, oRowId}. All entries in the covariate table
638-
#' must be sorted in increasing order by {cRowId}. Each cRowId value must match exactly one oRowId value.
637+
#' All entries in the outcome table must be sorted in increasing order by (oStratumId, oRowId). All entries in the covariate table
638+
#' must be sorted in increasing order by (cRowId). Each cRowId value must match exactly one oRowId value.
639639
#'
640640
#' @param object OHDSI Cyclops data object to append entries
641641
#' @param oStratumId Integer vector (optional): non-unique stratum identifier for each row in outcomes table

0 commit comments

Comments
 (0)