Learn R Programming

pedtools (version 2.8.0)

newMarker: Internal marker constructor

Description

This is the internal constructor of marker objects. It does not do any input validation and should only be used in programming scenarios, and only if you know what you are doing. Most users are recommended to use the regular constructor marker().

Usage

newMarker(
  alleleMatrixInt,
  alleles,
  afreq,
  name = NA_character_,
  chrom = NA_character_,
  posMb = NA_real_,
  mutmod = NULL,
  pedmembers,
  sex
)

Value

A marker object.

Arguments

alleleMatrixInt

An integer matrix.

alleles

A character vector.

afreq

A numeric vector.

name

A character of length 1.

chrom

A character of length 1.

posMb

A numeric of length 1.

mutmod

A mutation model.

pedmembers

A character vector.

sex

An integer vector.

Details

See marker() for more details about the marker attributes.

Examples

Run this code

newMarker(matrix(c(1L, 0L, 1L, 1L, 0L, 2L), ncol = 2),
          alleles = c("A", "B"), afreq = c(0.1, 0.9), name = "M",
          pedmembers = c("1", "2", "3"), sex = c(1L, 2L, 1L))

Run the code above in your browser using DataLab