getSummary: Compute summary information

Description Usage Arguments Details Value Examples

View source: R/wga_stat.R

Description

Returns a matrix of estimated parameters, standard errors, test statistics, and p-values.

Usage

1
 getSummary(fit, sided=2, method=NULL)

Arguments

fit

The return object from snp.logistic, snp.matched, glm(), or a list with names "parms" and "cov" containing parameter estimates and the variance-covariance matrix for the estimates. No default.

sided

1 or 2 for a 1 or 2 sided p-values. The default is 2.

method

Vector of values from "UML", "CML", "EB" or "CCL", "HCL", "CLR". The default is NULL.

Details

This function returns a matrix similar to summary(glm.obj)$coefficients, except the p-values are always computed using the normal distribution.

Value

A matrix with column names "Estimate", "Std.Error", "Z.value", and "Pvalue". The rownames of the returned matrix will be the names of parms if parms is a vector.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
 parms <- 1:5
 cov   <- matrix(data=1, nrow=5, ncol=5)
 getSummary(list(parms=parms, cov=cov))

 # Compare to summary()
 set.seed(123)
 n <- 100
 y <- rbinom(n, 1, 0.5)
 x <- cbind(runif(n), rbinom(n, 1, 0.5))
 fit <- glm(y ~ x, family=binomial())
 sum <- summary(fit)
 sum$coefficients
 getSummary(fit)

CGEN documentation built on April 28, 2020, 8:08 p.m.