publish.Score: Publish predictive accuracy results

View source: R/publish.Score.R

publish.ScoreR Documentation

Publish predictive accuracy results

Description

Write output of riskRegression::Score in tables

Usage

## S3 method for class 'Score'
publish(object, metrics, score = TRUE, contrasts = TRUE, level = 3, ...)

Arguments

object

Object obtained with riskRegression::Score

metrics

Which metrics to put into tables. Defaults to object$metrics.

score

Logical. If TRUE print the score elements, i.e., metric applied to the risk prediction models.

contrasts

Logical. If TRUE print the contrast elements (if any). These compare risk prediction models according to metrics.

level

Level of subsection headers, i.e., ** for level 2 and *** for level 3 (useful for emacs org-users). Default is plain subsection headers no stars. A negative value will suppress subjection headers.

...

Passed to publish

Details

Collect prediction accuracy results in tables

Value

Results of Score in tabular form

Author(s)

Thomas A. Gerds <tag@biostat.ku.dk>

Examples

if (requireNamespace("riskRegression",quietly=TRUE)){
library(riskRegression)
library(survival)
learn = sampleData(100)
val= sampleData(100)
f1=CSC(Hist(time,event)~X1+X8,data=learn)
f2=CSC(Hist(time,event)~X1+X5+X6+X8,learn)
xs=Score(list(f1,f2),data=val,formula=Hist(time,event)~1)
publish(xs)
}

Publish documentation built on Jan. 18, 2023, 1:08 a.m.