plot_roc_curve | R Documentation |
Plot roc curve
plot_roc_curve(test_result)
test_result |
result of test_classifier function |
ggplot2 roc curve
# load small example dataset
data("tirosh_mel80_example")
# train a classifier, for ex: B cell
selected_marker_genes_B = c("CD19", "MS4A1", "CD79A")
set.seed(123)
classifier_b <- train_classifier(train_obj = tirosh_mel80_example,
assay = 'RNA', slot = 'counts', marker_genes = selected_marker_genes_B,
cell_type = "b cells", tag_slot = 'active.ident')
classifier_b_test <- test_classifier(classifier = classifier_b,
test_obj = tirosh_mel80_example, assay = 'RNA', slot = 'counts',
tag_slot = 'active.ident', target_cell_type = c("B cell"))
# run plot curve on the test result
roc_curve <- plot_roc_curve(test_result = classifier_b_test)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.