Description Usage Arguments Details Value Author(s) References See Also Examples
Writes genotype data file in GenAlEx format from an annotated data frame
of class genalex
to an Excel worksheet. Both .xls
and
.xlsx
formats may be written. This function uses the function
writeWorksheet
and others from the
XLConnect
package to write the Excel file. Strings representing NA
values are
strictly those allowed by GenAlEx itself, 0 and -1. The worksheet is
written using the default formatting of the XLConnect
package.
1 2 | writeGenalexExcel(x, file, worksheet, na = c("0", "-1"), na.character = "",
check.annotation = TRUE, overwrite = FALSE)
|
x |
Annotated data frame of class |
file |
Excel workbook file to which to write the worksheet |
worksheet |
Worksheet name in a format valid for Excel, see
|
na |
The string to use when writing missing values in genotype
data. Defaults to |
na.character |
The string to use when writing missing values in
character data. Defaults to |
check.annotation |
If |
overwrite |
If |
Only the first column for each locus is given a heading, specifically the locus name. The other columns representing further alleles for the locus are left blank.
Any extra columns of data, if present in the object of class
genalex
, are written immediately to the right of the genotype
columns.
For further information and cautions, see writeGenalex
.
No value is returned.
Douglas G. Scofield
Peakall, R. and Smouse P.E. (2012) GenAlEx 6.5: genetic analysis in Excel. Population genetic software for teaching and research-an update. Bioinformatics 28, 2537-2539.
Peakall, R. and Smouse P.E. (2006) GENALEX 6: genetic analysis in Excel. Population genetic software for teaching and research. Molecular Ecology Notes 6, 288-295.
readGenalexExcel
, writeGenalex
, writeWorksheet
createSheet
1 2 3 4 5 6 | data(Qagr_adult_genotypes)
d <- head(Qagr_adult_genotypes)
## recalculate class attributes
d <- as.genalex(d, force = TRUE)
## create Excel worksheet, will not overwrite existing
writeGenalexExcel(d, "test.xlsx", "test")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.