model.evaluation.plot: Model Evaluation Plot

View source: R/model_evaluation_plot.r

model.evaluation.plotR Documentation

Model Evaluation Plot

Description

Produces plots for model evaluation.

Usage

model.evaluation.plot(..., fn.plot = NULL, 
colours=NULL, show.all=FALSE, verbose = 1)

Arguments

...

one or more object of class siamcat-class, can be named

fn.plot

string, filename for the pdf-plot

colours

colour specification for the different siamcat-class- objects, defaults to NULL which will cause the colours to be picked from the 'Set1' palette

show.all

boolean, Should the results from repeated cross-validation models be plotted? Defaults to FALSE, leading to a single line for the mean across cross-valdiation repeats

verbose

control output: 0 for no output at all, 1 for only information about progress and success, 2 for normal level of information and 3 for full debug information, defaults to 1

Value

Does not return anything, but produces the model evaluation plot.

Binary classification problems

The first plot shows the Receiver Operating Characteristic (ROC)-curve, the other plot the Precision-recall (PR)-curve for the model. If show.all == FALSE (which is the default), a single line representing the mean across cross-validation repeats will be plotted, otherwise the individual cross-validation repeats will be included as lightly shaded lines.

Regression problems

For regression problems, this function will produce a scatter plot between the real and predicted values. If several siamcat-class-objects are supplied, a single plot for each object will be produced.

Examples

data(siamcat_example)

# simple working example
model.evaluation.plot(siamcat_example, fn.plot='./eval.pdf')

# plot several named SIAMCAT object
# although we use only one example object here
model.evaluation.plot('Example_1'=siamcat_example,
    'Example_2'=siamcat_example, colours=c('red', 'blue'),
    fn.plot='./eval.pdf')
    
# show indiviudal cross-validation repeats
model.evaluation.plot(siamcat_example, fn.plot='./eval.pdf', show.all=TRUE)

zellerlab/siamcat documentation built on Feb. 1, 2024, 2:21 a.m.