getFixedParameter: Get fixed allele read biases and mismapping rate

getFixedParameterR Documentation

Get fixed allele read biases and mismapping rate

Description

Get fixed allele read biases and mismapping rates of markers

Usage

getFixedParameter(object, valid = TRUE, chr = NULL, ...)

## S4 method for signature 'GbsrGenotypeData'
getFixedParameter(object, valid, chr)

Arguments

object

A GbsrGenotypeData object.

valid

A logical value. See details.

chr

A integer or string to specify chromosome to get information.

...

Unused.

Details

If valid = TRUE, A logical vector for the markers which are labeled TRUE in the "valid" column of the "marker" slot will be returned. If you need check the dominant markers in all markers, set valid = FALSE. validMar() tells you which markers are valid.

Value

A numeric vector of fixed allele read biases.

A GbsrGenotypeData object after adding dominant marker information

See Also

setFixedParameter()

Examples

vcf_fn <- system.file("extdata", "sample.vcf", package = "GBScleanR")
gds_fn <- tempfile("sample", fileext = ".gds")
gbsrVCF2GDS(vcf_fn = vcf_fn, out_fn = gds_fn, force = TRUE)

# Load data in the GDS file and instantiate a [GbsrGenotypeData] object.
gds <- loadGDS(gds_fn)

# Not run.
# Run estGeno() and reuse the estimated parameters in the second run.
# gds <- makeScheme(gds, generation = 2, crosstype = "self")
# gds <- estGeno(gds)
# fixed_param <- getFixedParameter(gds)
# gds <- setFixedParameter(gds,
#                          bias = fixed_param$bias,
#                          mismap = fixed_param$mismap)
# gds <- estGeno(gds, optim = FALSE, call_threshold = 0.5)

# Close the connection to the GDS file
closeGDS(gds)


tomoyukif/GBScleanR documentation built on June 1, 2025, 10:13 p.m.