Learn R Programming

BPEC (version 1.3.1)

bpec.loadCoords: Load location data

Description

Create R objects of locations from corresponding file.

Usage

bpec.loadCoords(coordsFile, header = FALSE)

Arguments

coordsFile

The name of the coordinate and sequence file in full, eg "coordsLocs.txt".

header

If TRUE, then the first row of the file is assumed to be variable names.

Value

coordsLocs

R object of locations and corresponding haplotypes.

Details

Given the names of the file, this command will create an R objects of the coordinates and locations that can be fed into bpec.mcmc.

Examples

Run this code
# NOT RUN {
#to load existing example file from BPEC
coordsFile <- system.file("coordsLocsFile.txt",package = "BPEC")
coordsLocs <- bpec.loadCoords(coordsFile, header = TRUE)

# }
# NOT RUN {
#to load a different input file "coordsLocs.txt"
coordsLocs <- bpec.loadCoords("coordsLocs.txt", header = TRUE)
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab