R/basic.distribution.R

basic.distribution <-
function (distribution) 
{
    switch.dist <- generic.distribution(distribution)
    switch(switch.dist, exponential = , sev = , weibull = {
        ret.distribution <- "sev"
    }, lev = , frechet = {
        ret.distribution <- "lev"
    }, normal = , lognormal = {
        ret.distribution <- "normal"
    }, loglogistic = , logistic = {
        ret.distribution <- "logistic"
    }, {
        stop(paste("Distribution", distribution, switch.dist, 
            "not recognized"))
    })
    return(ret.distribution)
}

Try the teachingApps package in your browser

Any scripts or data that you put into this service are public.

teachingApps documentation built on July 1, 2020, 5:58 p.m.