groupMatSingle: Grouping a Half-sib Family

View source: R/groupMatSingle.R

groupMatSingleR Documentation

Grouping a Half-sib Family

Description

Group the genotype or haplotype of a half-sib family into partitions using opposing homozygotes.

Usage

groupMatSingle(haplotype, windowsSize, cpus = 2, input = "haplotype", oh = 0)

Arguments

haplotype

matrix. Haplotypes (two rows per individual) or genotypes (one row per individual) depending on input.

windowsSize

integer. Partition size.

cpus

integer. Number of CPU threads.

input

character. Either "haplotype" or "genotype".

oh

integer. Threshold for opposing homozygotes used for grouping (increase if genotyping errors exist).

Value

A grouping matrix.

See Also

addSwitch and fixSW

Examples

haplotype <- .simulateHalfsib(10, 5000, type = "haplotype")$phased
gMat <- groupMatSingle(haplotype, 100, 2, "haplotype")
imageplot(gMat)

hsphase documentation built on Feb. 17, 2026, 5:07 p.m.