Learn R Programming

PopGenome (version 1.2.6)

set.populations-methods: Define populations

Description

This generic function defines the populations. The advantage of this function is, that you don't have to specify the populations for each calculation. The populations are set for each statistic module.

Usage

## S3 method for class 'GENOME':
set.populations(object,new.populations=FALSE, diploid=FALSE)

Arguments

object
an object of class "GENOME"
new.populations
list of populations. default:FALSE
diploid
if diploid data is present

Examples

Run this code
# GENOME.class <- readData("\home\Alignments")
# pop.1 <- c("seq1","seq2")
# pop.2 <- c("seq3","seq4","seq1")
# GENOME.class <- set.populations(GENOME.class,list(pop.1,pop.2))
# GENOME.class <- neutrality.stats(GENOME.class)

Run the code above in your browser using DataLab