dot-summarizeCols: Summarize columns of matrix (or data.frame) 'x' using apply...

.summarizeColsR Documentation

Summarize columns of matrix (or data.frame) 'x' using apply (main)

Description

This function summarizes columns of matrix (or data.frame) 'x' using apply In case of character entries the 'median' of sorted values will be returned

Usage

.summarizeCols(
  x,
  me = "median",
  nEq = FALSE,
  vectAs1row = TRUE,
  supl = NULL,
  silent = FALSE,
  debug = FALSE,
  callFrom = NULL
)

Arguments

x

data.frame matrix of data to be summarized by comlumn

me

(character, length=1) summarization method (eg 'min','max','mean','mean.trim','median','sd','CV', 'medianComplete' or 'meanComplete' etc, see summarizeCols)

nEq

(logical) if TRUE, add additional column indicating the number of equal lines for choice (only with min or max)

vectAs1row

(logical) if TRUE will interprete non-matrix 'x' as matrix with 1 row (correct effect of automatic conversion when extracting 1 line)

supl

(numeric) supplemental parameters for the various summarizing functions (currently used with 'me=mean.trim' to assign upper and lower trimming fraction, passed to )

silent

(logical) suppress messages

debug

(logical) additional messages for debugging

callFrom

(character) allow easier tracking of messages produced

Value

vector with summary for each column (unless 'me=="summary"', in this case a matrix or list will be returned )

See Also

summarizeCols, table table

Examples

m1 <- matrix(c(28,27,11,12,11,12), nrow=2, dimnames=list(1:2,c("y","x","ref")))
.summarizeCols(m1, me="median")

wrMisc documentation built on Sept. 11, 2024, 6:10 p.m.