print.nbc_summary: Print top predicted causes from a NBC model

Description Usage Arguments Details See Also Examples

View source: R/nbc4va_main.R

Description

Prints a summary message from a summary.nbc object of the top causes by probability or predicted Cause Specific Mortality Fraction (CSMF).

printnbcex.png

Usage

1
2
## S3 method for class 'nbc_summary'
print(x, ...)

Arguments

x

A summary.nbc object.

...

Additional arguments to be passed if applicable.

Details

See Methods documentation for details on CSMF and probability from the Naive Bayes Classifier.

See Also

Other main functions: nbc, plot.nbc, summary.nbc

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
library(nbc4va)
data(nbc4vaData)

# Run naive bayes classifier on random train and test data
train <- nbc4vaData[1:50, ]
test <- nbc4vaData[51:100, ]
results <- nbc(train, test)

# Print a summary of all the test data for the top 3 causes by predicted CSMF
brief <- summary(results, top=3)
print(brief)

nbc4va documentation built on May 2, 2019, 1:42 p.m.