by.loci {pegas}R Documentation

Summary by Population or Other Factor

Description

This is an implementation of the generic by function which applies a function to some data for a each level of a categorical factor.

Usage

## S3 method for class 'loci'
by(data, INDICES = data$population, FUN = NULL, ..., simplify = TRUE)

Arguments

data

an object of class "loci".

INDICES

a vector of the same length as the number of rows in data.

FUN

a function

...

(currently unused).

simplify

(currently unused).

Details

The default FUN = NULL calculates allele frequencies for each population in data.

Value

a list by default indexed by locus.

Author(s)

Emmanuel Paradis

See Also

by

Examples

data(jaguar)
by(jaguar)
by(na.omit(jaguar))

[Package pegas version 1.3 Index]