pbg {profileR}R Documentation

Profile Analysis by Group: Testing Parallelism, Equal Levels, and Flatness

Description

The pbg function implements three hypothesis tests. These tests are whether the profiles are parallel, have equal levels, and are flat across groups defined by the grouping variable. If parallelism is rejected, the other two tests are not necessary. In that case, flatness may be assessed within each group, and various within- and between-group contrasts may be analyzed.

Usage

pbg(data, group, original.names = FALSE, profile.plot = FALSE)

Arguments

data

A matrix or data frame with multiple scores; rows represent individuals, columns represent subscores. Missing subscores have to be inserted as NA.

group

A vector or data frame that indicates a grouping variable. It can be either numeric or character (e.g., male-female, A-B-C, 0-1-2). The grouping variable must have the same length of x. Missing values are not allowed in y.

original.names

Use original column names in x. If FALSE, variables are renamed using v1, v2, ..., vn for subscores and "group" for the grouping variable. Default is FALSE.

profile.plot

Print a profile plot of scores for the groups. Default is FALSE.

Value

An object of class profg is returned, listing the following components:

See Also

pr, profileplot

Examples

## Not run: 
data(spouse)
mod <- pbg(data=spouse[,1:4], group=spouse[,5], original.names=TRUE, profile.plot=TRUE)
print(mod) #prints average scores in the profile across two groups
summary(mod) #prints the results of three profile by group hypothesis tests

## End(Not run)

[Package profileR version 0.3-5 Index]