R/print.ctab2.R

Defines functions print.ctab2

Documented in print.ctab2

print.ctab2 <-
function(x, ...){

    CALL <- x$CALL
    tab <- x$tab
    tab.p <- x$tab.p
    digits <- x$digits
    
    #cat("\n")
    #print(CALL)
    #cat("\n")
    #cat("\n------------------------------------ Table description \n\n")
    
    #cat("\n")
    #if(length(attr(terms(x$f), "term.labels")) > 0)
    #    z <- paste ("Contingency table ", paste(dim(tab), collapse = "-by-", sep = ""), sep = "")
    #else
    #    z <- paste ("Contingency table 1-by-", dim(tab), sep = "")
    #cat(z, "\n\n")

    cat("\n\n $ Counts: \n\n")
    print(tab)
    cat("\n\n$ Row percentages: \n\n")
    print(tab.p)
    cat("\n")
    
    }

Try the tdisplay package in your browser

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

tdisplay documentation built on May 2, 2019, 4:46 p.m.