Skip to content

Poduval/rcctvm

Repository files navigation

rcctvm

The goal of rcctvm is to produce top notch statistical models in bio medical research.

Installation

You can install the development version of rcctvm from GitHub with:

pak::pak("Poduval/rcctvm")

Examples

Basic functions

This is a basic example which shows you how to solve a common problem:

library(rcctvm)
#> Attached R package from Regional Cancer Centre, Thiruvananthapuram
add2vars(2, 3)
#> [1] 5

Predictions with survival model

Single input

predict_risk(sex = "female", wbc = 2.1, treatment = "new")
#>         1 
#> 0.1553109
predict_risk(sex = "male", wbc = 4.3, treatment = "standard")
#>         1 
#> 0.0841474

Vector input

predict_risk(sex = c("female", "male"),  wbc = c(2.1, 4.3), 
             treatment = c("new", "standard"))
#>         1         2 
#> 0.1553109 0.0841474

Data frame input

testdata <- data.frame(
  sex = c("female", "male"), 
  wbc = c(2.1, 4.3),
  treatment = c("new", "standard"))

predict_risk(x = testdata)
#>         1         2 
#> 0.1553109 0.0841474

About

Demo package for regional cancer centre, Trivandrum

Resources

License

Unknown, MIT licenses found

Licenses found

Unknown
LICENSE
MIT
LICENSE.md

Stars

Watchers

Forks

Packages

No packages published