Tidying methods for fitdistr objects from the MASS package

Description

These methods tidies the parameter estimates resulting from an estimation of a univariate distribution's parameters.

Usage

1
2
3
4
5
## S3 method for class 'fitdistr'
tidy(x, ...)

## S3 method for class 'fitdistr'
glance(x, ...)

Arguments

x

An object of class "fitdistr"

...

extra arguments (not used)

Value

All tidying methods return a data.frame without rownames, whose structure depends on the method chosen.

tidy.fitdistr returns one row for each parameter that was estimated, with columns:

term

The term that was estimated

estimate

Estimated value

std.error

Standard error of estimate

glance.fitdistr returns a one-row data.frame with the columns

n

Number of observations used in estimation

logLik

log-likelihood of estimated data

AIC

Akaike Information Criterion

BIC

Bayesian Information Criterion

Examples

1
2
3
4
5
6
7
8
set.seed(2015)
x <- rnorm(100, 5, 2)

library(MASS)
fit <- fitdistr(x, dnorm, list(mean = 3, sd = 1))

tidy(fit)
glance(fit)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.