Description Usage Arguments Value Author(s) See Also Examples
View source: R/read_genalexcel.R
The poppr function read.genalex
provides a way to
read GenAlEx formatted data into R. The only stipulation is that the file
must be saved as a CSV text file beforehand. This function provides a wrapper
for read.genalex
and read_excel
from the readxl package.
1 | read.genalexcel(x, sheet = 1, ...)
|
x |
a path to your excel file |
sheet |
the sheet in which your data is contained. |
... |
any arguments to be passed on to |
a genclone
or genind
object.
Zhian N. Kamvar
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | # Read in the data set nancycats from an example excel file in this
# package.
nancy <- system.file("files/nancycats.xlsx", package = "popprxl")
nancy # This is the address to our excel file.
read.genalexcel(nancy, sheet = 1, genclone = FALSE)
# Note that system.file() is only for examples. You can use
# file.choose() for an interactive way of choosing files.
#
# e.g.
# myfile <- file.choose()
# read.genalexcel(myfile)
## Not run:
nancy_ex_rows <- system.file("files/nancycats_extra_rows.xlsx", package = "popprxl")
# This will give a warning
read.genalexcel(nancy_ex_cols, sheet = 1, genclone = FALSE)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.