Learn R Programming

TestDimorph (version 0.3.0)

extract_sum: Summary Statistics Extraction

Description

Extract summary data needed for other functions from raw data.

Usage

extract_sum(x, Sex = 1, Pop = 2, firstX = 3, test = 1, run = TRUE, ...)

Arguments

x

Tibble/data frame containing raw data.

Sex

Number of the column containing sex 'M' for male and 'F' for female, Default: 1

Pop

Number of the column containing populations' names, Default: 2

firstX

Number of column containing measured parameters (First of multiple in case of multivariate analysis), Default: 3

test

1 for Greene t-test Tg, 2 for univariate, 3 for sex specific ANOVA aovSS, and 4 for multivariate, Default: 1

run

Logical; if TRUE runs the corresponding test after data extraction, Default: TRUE

...

Additional arguments that could be passed to the test of choice

Value

Input for other functions.

Details

Raw data is entered in a wide format tibble/data frame similar to Howells data set. The first two columns contain sex Sex (M for male and F for female) (Default: 1) and populations' names Pop (Default: 2). Starting from firstX column (Default: 3), measured parameters are entered each in a separate column.

Examples

Run this code
# NOT RUN {
# for multivariate test
library(TestDimorph)
extract_sum(Howells,test=4)
# for univariate test on a specific parameter
library(TestDimorph)
extract_sum(Howells, test = 2,firstX = 4)

# }

Run the code above in your browser using DataLab