prequential.score {DNAmixturesLite} | R Documentation |
Calculate prequential scores
Description
IMPORTANT: This is the DNAmixturesLite package, which is intended as a service to enable users to try DNAmixtures without purchasing a commercial licence for Hugin. When at all possible, we strongly recommend the use of DNAmixtures rather than this lite-version. See https://dnamixtures.r-forge.r-project.org/ for details on both packages.
While the lite-version seeks to provide the full functionality of DNAmixtures, note that computations are much less efficient and that there are some differences in available functionality. Be aware that the present documentation is copied from DNAmixtures and thus may not accurately describe the implementation of this lite-version.
Usage
prequential.score(mixture, pars, markers = mixture$markers, by.allele = TRUE)
## S3 method for class 'prequential.score'
plot(x, normalise = FALSE, ylab = NULL, ylim = NULL, ...)
Arguments
mixture |
A |
pars |
A |
markers |
An ordering of the markers, possibly a subset of the markers only. |
by.allele |
Should conditioning be done allele-wise ( |
x |
A data.frame containing at least variables |
normalise |
Should the prequential score be normalised? Defaults to |
ylab |
Label for the y-axis. |
ylim |
Range for the y-axis. |
... |
Additional arguments to be passed on to |
Value
A data.frame, which contains the output from
predict
as well as columns Y
, EY
, VY
, corresponding
to the log-score and its mean and variance. Finally the variable
score
is added, which is the normalised cumulative log-score.
Author(s)
Therese Graversen
Examples
data(MC15, MC18, USCaucasian)
mix <- DNAmixture(list(MC15, MC18), C = list(50,50), k = 3, K = c("K1", "K3"),
database = USCaucasian)
p <- mixpar(rho = list(30, 30), eta = list(30, 30), xi = list(0.08,0.08),
phi = list(c(U1 = 0.1, K3 = 0.2, K1 = 0.7), c(U1 = 0.1, K3 = 0.2, K1 = 0.7)))
preq <- prequential.score(mix, pars = p)
plot(preq, col = preq$trace)
## Annotate using repeat numbers
text(preq$score, labels = preq$allele, pos = c(1,3), col = preq$trace, cex = 0.6)