Learn R Programming

pergola (version 1.0)

map2dend: Transforming a map into a dendrogram

Description

Create dendrogram object. The map specific distance are ignored and only the grouping and ordering is maintained. Allows for comparison of whole map with package 'dendextend'

Usage

map2dend(map, mergeoff = 0L)

Arguments

map
One map. Required.
mergeoff
Numeric, offset between chromosomes, to avoid equal heights in dendrogram. Equal heights lead to problems in cor_bakers_gamma().

Value

Dendogram object.

Examples

Run this code
data(simTetra)
simTetrageno <- bases2genotypes(simTetra, 4)
rfMat <- calcRec(simTetrageno, 4)
split <- splitChr(rfMat, nchr = 7)
split <- sortLeafs(rfMat, split)
map <- pullMap(rfMat, split = split)   
dend <- map2dend(map)  
plot(dend)

Run the code above in your browser using DataLab