Description Usage Arguments Value Author(s) See Also Examples
View source: R/ancestrymap2lfmm.R
A function that converts from the ancestrymap
format to the
lfmm
format.
1 | ancestrymap2lfmm(input.file, output.file = NULL, force = TRUE)
|
input.file |
A character string containing a path to the input file,
a genotypic matrix in the |
output.file |
A character string containing a path to the output file,
a genotypic matric in the |
force |
A boolean option. If FALSE, the input file is converted only if the output file does not exist. If TRUE, convert the file anyway. |
output.file |
A character string containing a path to the output file,
a genotypic matric in the |
Eric Frichot
ancestrymap
lfmm.data
ancestrymap2geno
geno2lfmm
ped2lfmm
ped2geno
vcf2geno
lfmm2geno
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | # Creation of a file called "example.ancestrymap"
# containing 4 SNPs for 3 individuals.
data("example_ancestrymap")
write.table(example_ancestrymap,"example.ancestrymap",
col.names = FALSE, row.names = FALSE, quote = FALSE)
# Conversion from the ancestrymap format ("example.ancestrymap")
# to the lfmm format ("example.lfmm").
# By default, the name of the output file is the same name
# as the input file with a .lfmm extension.
# Create file: "example.lfmm".
output = ancestrymap2lfmm("example.ancestrymap")
# Conversion from the ancestrymap format (example.ancestrymap)
# to the geno format with the output file called plop.lfmm.
# Create file: "plop.lfmm".
output = ancestrymap2lfmm("example.ancestrymap", "plop.lfmm")
# As force = false and the file "example.lfmm" already exists,
# nothing happens.
output = ancestrymap2lfmm("example.ancestrymap", force = FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.