help for gengroupJean-benoit Hardouin

Module to generate group of individuals based on a ordinal or continuous variable

gengroup varname [if exp] [in range] [, newvariable(newvarname) replace minsize(#) details continuous]

Description

gengroup creates groups of individuals by using the values of an ordinal or continuous variable.
The module creates groups by recoding several adjacent values of the variable, until obtaining groups with more than individuals than the number defined in the minsize option.

Options

newvariable defines the name of the new variable (group by default).

replace replaces the variable defined in the newvariable option if it already exists.

minsize defines the minimal number of individuals in each group (30 by default).

details diplays the composition of each group.

continuous allows handling a continuous variable.

Examples

. gengroup score

. gengroup score, newvariable(grouptocreate) replace minsize(80)

. gengroup score, details

Author

Jean-Benoit Hardouin, PhD, assistant professor

Team of Biostatistics, Clinical Research and Subjective Measures in Health Sciences

University of Nantes - Faculty of Pharmaceutical Sciences

1, rue Gaston Veil - BP 53508

44035 Nantes Cedex 1 - FRANCE

Email:
jean-benoit.hardouin@univ-nantes.fr

Website AnaQol

Also see

Online: help for egen, generate and genscore if installed.