R/get.response.units.R

get.response.units <-
function (data.d, warn = F)
{
    response.units <- attr(data.d, "response.units")
    if (is.null(response.units))
        response.units <- attr(data.d, "time.units")
    if (is.null(response.units))
        response.units <- attr(data.d, "response.column")
    if (is.null(response.units))
        response.units <- data.d$response.units
    if (is.null(response.units)) {
        if (warn)
            warning("no response units")
        response.units <- ""
    }
    return(response.units)
}
Auburngrads/SMRD documentation built on Sept. 14, 2020, 2:21 a.m.