Description Usage Arguments Value Note Author(s) Examples
This class provides a standard structure for information on markers (e.g. mitochondrial DNA samples) from a variety of different sources (e.g. sources) and from (a) mixed population(s) that draw(s) from those sources.
1 2 3 4 5 6 7 | as.mixstock.data(object,nmix=1,sourcesize)
## S3 method for class 'mixstock.data'
plot(x,prop = TRUE, legend = TRUE, colors = rainbow(x$H),
leg.space = 0.3, leg.ncol, leg.cex=1, mix.off = 0.5,
stacklabels=FALSE, sampsize=FALSE, horiz=TRUE, vlab="Haplotype frequency", ...)
## S3 method for class 'mixstock.data'
print(x,...)
|
object |
a matrix with (R+1) columns and (H) rows, where the columns specify R sources plus a mixed population, and the rows specify distinct marker classes (e.g. mitochondrial haplotypes) |
x |
a |
prop |
reduce data to frequencies? |
legend |
add a legend to the plot? |
colors |
colors denoting different markers |
horiz |
logical: plot bars horizontally? |
leg.space |
space to leave for legend (fraction at top of graph) |
leg.ncol |
number of columns for legend (default is 3 for horizontal barplots, 1 for vertical) |
leg.cex |
character size for legend |
mix.off |
spacing offset for bar(s) representing mixed stock(s) |
stacklabels |
(logical) put source names on multiple lines? |
sampsize |
(logical) add text showing sample sizes? |
nmix |
number of mixed stocks (default 1) |
sourcesize |
either a numeric vector of relative source sizes, or "first" or "last" to specify that the first or last row of the matrix contains the source sizes |
vlab |
label for value axis |
... |
additional arguments to |
mixstock.data
objects have the following components:
R |
number of sources |
H |
number of marker classes (haplotypes) |
sourcesamp |
samples from sources, in an HxR matrix |
mixsamp |
a vector of sample from the mixed population |
print.mixstock.data
and plot.mixstock.data
give
textual and graphical summaries of the results
While vertical barplots are more familiar, horizontal barplots are useful for displaying long source/mixed stock names
Ben Bolker
1 2 3 4 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.