Learn R Programming

HardyWeinberg (version 1.7.8)

GenerateSamples: Generate genotypic compositions

Description

GenerateSamples generates all possible genotypic compositions (AA,AB,BB) for a given sample size n.

Usage

GenerateSamples(n = 5)

Value

returns a matrix with in each row a possible genotypic compostion for the given sample size.

Arguments

n

the desired sample size

Author

Jan Graffelman jan.graffelman@upc.edu

Examples

Run this code
GenerateSamples(5)

Run the code above in your browser using DataLab