Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8a85d3a
commit 60c5d80
Showing
21 changed files
with
723 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# 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] | ||
|
||
name: test-coverage | ||
|
||
jobs: | ||
test-coverage: | ||
runs-on: ubuntu-latest | ||
env: | ||
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: r-lib/actions/setup-r@v2 | ||
with: | ||
use-public-rspm: true | ||
|
||
- uses: r-lib/actions/setup-r-dependencies@v2 | ||
with: | ||
extra-packages: any::covr | ||
needs: coverage | ||
|
||
- name: Test coverage | ||
run: | | ||
covr::codecov( | ||
quiet = FALSE, | ||
clean = FALSE, | ||
install_path = file.path(Sys.getenv("RUNNER_TEMP"), "package") | ||
) | ||
shell: Rscript {0} | ||
|
||
- name: Show testthat output | ||
if: always() | ||
run: | | ||
## -------------------------------------------------------------------- | ||
find ${{ runner.temp }}/package -name 'testthat.Rout*' -exec cat '{}' \; || true | ||
shell: bash | ||
|
||
- name: Upload test results | ||
if: failure() | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: coverage-test-failures | ||
path: ${{ runner.temp }}/package |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#' @keywords internal | ||
"_PACKAGE" | ||
|
||
## usethis namespace: start | ||
#' @importFrom rlang .data | ||
## usethis namespace: end | ||
NULL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
comment: false | ||
|
||
coverage: | ||
status: | ||
project: | ||
default: | ||
target: auto | ||
threshold: 1% | ||
informational: true | ||
patch: | ||
default: | ||
target: auto | ||
threshold: 1% | ||
informational: true |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# pred_stacked_regression has expected output | ||
|
||
Code | ||
summary(SR) | ||
Output | ||
Information about 1 existing model(s) of type 'logistic' | ||
Model Coefficients | ||
================================= | ||
Intercept Age SexM Smoking_Status Diabetes Creatine | ||
1 -2.67512 0.005346913 0.1589209 0.5232909 0.2542794 0.4553747 | ||
Model Functional Form | ||
================================= | ||
Age + SexM + Smoking_Status + Diabetes + Creatine | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# output of pred_validate is as expected - single models | ||
|
||
Code | ||
print(val_results) | ||
Output | ||
Calibration Measures | ||
================================= | ||
Estimate Std. Err Lower 95% Confidence Interval | ||
Calibration-in-the-large 0.7323 0.0206 0.6921 | ||
Calibration Slope 0.6484 0.0463 0.5576 | ||
Upper 95% Confidence Interval | ||
Calibration-in-the-large 0.7726 | ||
Calibration Slope 0.7392 | ||
Also examine the calibration plot, if produced. | ||
Discrimination Measures | ||
================================= | ||
Estimate Std. Err Lower 95% Confidence Interval | ||
AUC 0.5814 0.0057 0.5702 | ||
Upper 95% Confidence Interval | ||
AUC 0.5927 | ||
Overall Performance Measures | ||
================================= | ||
Cox-Snell R-squared: -0.0481 | ||
Nagelkerke R-squared: -0.0863 | ||
Brier Score: 0.1249 | ||
Also examine the histogram of predicted risks. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# output of pred_validate is as expected - single models | ||
|
||
Code | ||
print(val_results) | ||
Output | ||
Calibration Measures | ||
================================= | ||
Estimate Std. Err Lower 95% Confidence Interval | ||
Observed:Expected Ratio 0.6319 0.0113 0.6181 | ||
Calibration Slope 1.0757 0.0389 0.9994 | ||
Upper 95% Confidence Interval | ||
Observed:Expected Ratio 0.6461 | ||
Calibration Slope 1.1519 | ||
Also examine the calibration plot, if produced. | ||
Discrimination Measures | ||
================================= | ||
Estimate Std. Err Lower 95% Confidence Interval | ||
Harrell C 0.5869 0.0032 0.5806 | ||
Upper 95% Confidence Interval | ||
Harrell C 0.5932 | ||
Also examine the histogram of predicted risks. | ||
|
Oops, something went wrong.