Gracias por responder tan rápido.
Con esto ya tengo suficiente. He mirado la función totPercents y esta ya me lo aclara.
> totPercents
function (tab, digits = 1)
{
dim <- length(dim(tab))
if (is.null(dimnames(tab))) {
dims <- dim(tab)
dimnames(tab) <- lapply(1:dim, function(i) 1:dims[i])
}
tab <- 100 * tab/sum(tab)
tab <- cbind(tab, rowSums(tab))
tab <- rbind(tab, colSums(tab))
rownames(tab)[nrow(tab)] <- "Total"
colnames(tab)[ncol(tab)] <- "Total"
round(tab, digits = digits)
}
<environment: namespace:Rcmdr>
Un saludo,
Franz
Foro de debate
Tablas de frecuencia con totales
This forum has a limit to the number of forum postings you can make in a given time period - this is currently set at 5 posting(s) in 1 day