GithubHelp home page GithubHelp logo

cumulcalib's Introduction

cumulcalib

R-CMD-check

The goal of cumulcalib is to enable the assessment of prediction model calibration using the cumulative calibration methodology. For more information, please refer to the original publication (https://doi.org/10.1002/sim.10138). The package also comes with a tutorial, which you can access on CRAN or view after installing the package as

vignette("tutorial", package="cumulcalib")

Installation

The package can be installed from CRAN:

install.packages("cumulcalib")

You can also install the development version from GitHub with:

# install.packages("remotes") #this package is necessary to connect to github
remotes::install_github("resplab/cumulcalib")

Example

library(cumulcalib)

set.seed(1)
p <- rbeta(1000, 1,5)
y <- rbinom(1000,1,p)

res <- cumulcalib(y, p)

summary(res)
#> C_n (mean calibration error): 0.00532270104567871
#> C* (maximum absolute cumulative calibration error): 0.00740996981029672
#> Method: Two-part Brownian Bridge (BB)
#> S_n (Z score for mean calibration error) 0.489295496431201
#> B* (test statistic for maximum absolute bridged calibration error): 0.904915434767163
#> Component-wise p-values: mean calibration=0.624632509005787 | Distance (bridged)=0.385979705481866
#> Combined p-value (Fisher's method): 0.584068794836004
#> Location of maximum drift: 812  | time value: 0.632911942275094  | predictor value: 0.28191196504736
plot(res, draw_sig=F)

cumulcalib's People

Contributors

msadatsafavi avatar

Stargazers

 avatar Owain  gaunders avatar

Watchers

Mehrshad Mokhtaran avatar Amin Adibi avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.