Description Usage Arguments Value Note Author(s) Examples
These functions allow to transform a RClone
table into files to work
with Adegenet
(R package), Genetix and Arlequin softwares.
1 2 3 | export_genclone_genind(data1, ele)
export_genclone_genetix(data1, haploid = FALSE, ele, name)
export_genclone_arlequin(data1, haploid = FALSE, name)
|
data1 |
a |
haploid |
logical, option, if |
ele |
option, separator element for export. |
name |
option, name of the exported file. |
a genind
object or a file for Genetix or Arlequin.
For multi-population files, we recommend to use split function to cut the table into
several tables, one for each population, and then combine lapply
with the export functions.
Creator/Author: Diane Bailleul <diane.bailleul.pro@gmail.com>
Author: Sophie Arnaud-Haond <sophie.arnaud@ifremer.fr>
Contributor: Solenn Stoeckel
The R implementation of RClone
was written by Diane Bailleul.
The design was inspired by GenClone program described in Arnaud-Haond & Belkhir (2007).
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | data(posidonia)
#RClone to Adegenet:
res <- export_genclone_genind(posidonia, "/")
#library(adegenet)
#res2 <- df2genind(res, ploidy = 2, sep = "/")
#nAll(res2)
#RClone to Genetix:
export_genclone_genetix(posidonia, name = "test.txt")
#or
write.table(export_genclone_genetix(posidonia), "test2.txt", row.names = FALSE,
sep = "\t", quote = FALSE)
#for genets only:
export_genclone_genetix(unique(posidonia), name = "test.txt")
#Rclone to Arlequin:
write.table(export_genclone_arlequin(posidonia), "file1.arp", row.names = FALSE,
col.names = FALSE, quote = FALSE)
#or
export_genclone_arlequin(posidonia, haploid = FALSE, "file2.arp")
#for genets only:
export_genclone_arlequin(unique(posidonia), haploid = FALSE, "file2.arp")
#if several populations:
#res <- split(data, vecpop)
#lapply(res, function(x) export_genclone_genetix(x))
#lapply(res, function(x) export_genclone_arlequin(x))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.