xyMultiStats: xyMultiStats

Description Usage Arguments Author(s) References See Also Examples

View source: R/xyMultiStats.R

Description

This function calculates distIUPAC based distances comparing all possible pairwise population combinations (x: receiver and y: donor).

Usage

1
2
3
4
xyMultiStats(dna, pop.list, chr.name = "chr", wlen = 25000,
  wjump = 25000, start.by = 1, end.by = NULL, wtype = "bp",
  dist = "IUPAC", global.deletion = TRUE, threads = 1, ncores = 1,
  pB = TRUE)

Arguments

dna

DNAStringSet [mandatory]

pop.list

population list with individual positions [mandatory]

chr.name

chromosome name [default: "chr"]

wlen

sliding windows length [default: 25000]

wjump

sliding windows jump [default: 25000]

start.by

optional start position [deafult: 1]

end.by

optional end position [deafult: NULL]

wtype

sliding windows type to use bp, biSites or triSites [default: "bp"]

dist

distance to use, choose one model as in dist.dna or [default: "IUPAC"]

global.deletion

a logical indicating whether to delete the sites with missing data in a global or pairwise way (default is to delete in a global way) [default: TRUE]

threads

number of parallel threads [default: 1]

ncores

number of parallel cores to process pairwise distance calculation [default: 1]

pB

specifies if progress should be shown as a progress bar [default: TRUE]

Author(s)

Kristian K Ullrich

References

Slatkin, M. (1991). Inbreeding coefficients and coalescence times. Genetics Research, 58(2), 167-175.

Beerli, P. (1998). Structured Populations. Advances in molecular ecology, 306, 39.

Reich, D., Thangaraj, K., Patterson, N., Price, A. L., & Singh, L. (2009). Reconstructing Indian population history. Nature, 461(7263), 489.

Patterson, N., Moorjani, P., Luo, Y., Mallick, S., Rohland, N., Zhan, Y., ... & Reich, D. (2012). Ancient admixture in human history. Genetics, 192(3), 1065-1093.

Peter, B. M. (2016). Admixture, population structure, and F-statistics. Genetics, 202(4), 1485-1501.

Paradis, E., & Schliep, K. (2018). ape 5.0: an environment for modern phylogenetics and evolutionary analyses in R. Bioinformatics, 35(3), 526-528.

See Also

xyStats, dist.dna

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
##load sequence data
data("MySequences", package="distIUPAC")
CAS.pos<-5:34
AFG.pos<-82:87
SPRE.pos<-106:113
pop.list<-setNames(list(CAS.pos, AFG.pos, SPRE.pos), c("CAS", "AFG",
"SPRE"))
##sliding windows based on base-pair length
CAS.AFG.SPRE.xyMultiStats<-xyMultiStats(MySequences, pop.list=pop.list,
threads = 2)
CAS.AFG.SPRE.xyMultiStats
#sliding windows based on biSites
CAS.AFG.SPRE.xyMultiStats<-xyMultiStats(MySequences, list.pos = pop.list,
wtype = "biSites", wlen = 50, threads = 2)
CAS.AFG.SPRE.xyMultiStats

kullrich/distIUPAC documentation built on Jan. 9, 2020, 2:50 p.m.