transpose_coordinates: Transpose coordinates in the SLiM 0-based coordinate system...

View source: R/vcf.R

transpose_coordinatesR Documentation

Transpose coordinates in the SLiM 0-based coordinate system into realistic coordinate system.

Description

SLiM simulates all mutations as part of a single continuous "chromosome". Therefore, simulating fixed mutations that are present in a real genome requires their transposition into a 0-based continuous coordinate system. This function performs this transposition based on the given positions of the sites in their original coordinate system.

Usage

transpose_coordinates(sim_coords, real_coords)

Arguments

sim_coords

GRanges object with SLiM, 0-based coordinates.

real_coords

GRanges object with real coordinate.

Details

The real_coords GRanges object must contain a DataFrame object with three columns specifying a realistic chromosome, start and end coordinate of a region.

Value

GRanges object with transposed coordinates.

See Also

read_coordinates


bodkan/slimr documentation built on Feb. 3, 2024, 3:39 p.m.