td.stats: General Statistics

Description Usage Arguments Details Value Examples

View source: R/td.stats.R

Description

This function uses the td data frame object passed in and retrieves some statistics for a particular column.

Usage

1
td.stats(tdf, col, which = "all", type = "population", group.by=NULL)

Arguments

tdf

td data frame.

col

name of column.

which

string or array of which statistics to return. Any of the follow are valid choices: ("cnt","min","max","mean","sum","uss","css","var","std","skew", "kurtosis","stderr","cvar"). You can also use "all" to retrieve them all.

type

whether to return the statistic based on the population or sample

group.by

td data frame of columns that are used to group your results.

Details

This function collects certain statistics from the Teradata table and returns them to the user via an R data frame. Count, minimum, maximum, mean, sum, uncorrected sum of squares, corrected sum of squares, variance, standard deviation, skewness, kurtosis, standard error, and coefficient of variance are statistics to choose from. You can also put a type of "all" to retrieve them all at once.

Value

data frame object with 1 row and the stats you have selected

Examples

1
2
3
4
## Not run: 
td.stats(tdf, "income", c("min","max","mean"))

## End(Not run)

nonsleepr/teradataR documentation built on May 23, 2019, 9:32 p.m.