Creates a list of parameters to use with DEoptim::DEoptim
.
1 2 3 4 5 
hypothesis 
Hypothesis from which to perform maximization 
verbose 
Wether to print likelihood each and every time the objective function is called 
fixed 
Names of the parameters to keep fixed 
logObjective 
If 
logDegradation 
If 
arguments 
Initial parameters from which to start the maximization. If

zero 
Epsilon to indicate lower and upper bounds as alpha +/ epsilon that exclude the bound itself 
throwError 
If TRUE, throws an error if the result is infinite 
withPenalties 
If TRUE, then penalties are evaluated and used 
doLinkage 
Logical indicating whether or not to apply a correction for linked loci.
This correction is only applied when Q and X are assumed to be siblings
i.e. 
objective 
Objective function produced from create.likelihood.vectors 
iterMax 
Number of iterations to run the optimisation for 
likeMatrix 
Whether to return likelihoods for every genotype combination, or
a likelihood summed over all genotypes after optimisation. Set to TRUE
for individual genotype likelihoods. This is used for

... 
Any named parameter to modify the hypothesis, e.g.

Starting from the hypothesis, it creates an list of arguments which can be
applied to DEoptim::DEoptim
to obtain the maximum (log)likelihood of that
hypothesis.
It accepts a number of customization:
The optimisation can be performed for the likelihood or the log of the likelihood. The latter is recommended.
wether the degradation
parameter should be inputs as x
or as an exponent 10^x. The latter seems to be more numerically
stable, likely because degradations (in first form) are factors of an
exponent in any case.
whether to keep some nuisance parameters fixed
In any case, the value returned can always be modified prior to calling
DEoptim::DEoptim
.
fn 
The objective function 
lower 
Lower bounds for the parameters 
upper 
Upper bounds for the parameters 
control 
Control parameters for 
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 29 30 31  ## Not run:
# datapath to example files
datapath = file.path(system.file("extdata", package="likeLTD"),"hammer")
# File paths and case name for allele report
admin = pack.admin.input(
cspFile = file.path(datapath, 'hammerCSP.csv'),
refFile = file.path(datapath, 'hammerreference.csv'),
caseName = "hammer",
kit= "SGMplus"
)
# Enter arguments
args = list(
nUnknowns = 1,
doDropin = FALSE,
ethnic = "EA1",
adj = 1,
fst = 0.02,
relatedness = c(0,0)
)
# Create hypotheses
hypP = do.call(prosecution.hypothesis, append(admin,args))
hypD = do.call(defence.hypothesis, append(admin,args))
# Get parameters for optimisation
paramsP = optimisation.params(hypP)
paramsD = optimisation.params(hypD)
## End(Not run)

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.
Please suggest features or report bugs with the GitHub issue tracker.
All documentation is copyright its authors; we didn't write any of that.