File: yz-getSummary_expcoef.R

package info (click to toggle)
r-cran-memisc 0.99.31.8.2%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 2,136 kB
  • sloc: ansic: 5,117; makefile: 2
file content (12 lines) | stat: -rw-r--r-- 379 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
getSummary_expcoef.default <- function (obj, alpha = 0.05, ...){
    res <- getSummary(obj=obj, alpha=alpha, ...)
    coef <- res$coef
    exp_coef <- coef
    exp_coef[,1,] <- exp(coef[,1,])
    # Based on the delta-method
    exp_coef[,2,] <- exp_coef[,1,]*coef[,2,]
    if(ncol(coef) ==6)
        exp_coef[,5:6,] <- exp(coef[,5:6,])
    res$coef <- exp_coef
    return(res)
}