output.report.peaks: likeLTD::output.report.peaks

Description Usage Arguments Details Examples

View source: R/reports-peaks.R

Description

Outputs a docx report of results.

Usage

1
2
output.report.peaks(prosecutionHypothesis,defenceHypothesis, 
                      results,file=NULL,figRes=300)

Arguments

prosecutionHypothesis

The output from prosecution.hypothesis.peaks.

defenceHypothesis

The output from defence.hypothesis.peaks.

results

The output from evaluate.peaks.

file

A file name for the output report. By default a filename is created to avoid over writing a previous file.

figRes

Resolution of figures in the output report. Defaults to 300 DPI.

Details

Creates a docx containing all results, placed in the directory specified by admin$outputPath. Results include both the pre-evaluation assessment of the crime-stain and reference profiles, and the post-evaluation results of the likelihoods and weight of evidence.

Examples

 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
32
33
34
35
36
37
38
## Not run: 
# datapath to example files
datapath = file.path(system.file("extdata", package="likeLTD"),"laboratory")

# File paths and case name for allele report
admin = pack.admin.input.peaks(
            peaksFile = file.path(datapath, 'laboratory-CSP.csv'),
            refFile = file.path(datapath, 'laboratory-reference.csv'),
            caseName = "Laboratory",
            detectionThresh = 20
             )

# Enter arguments
args = list(
        nUnknowns = 1
        )

# Create hypotheses
hypP = do.call(prosecution.hypothesis.peaks, append(admin,args))
hypD = do.call(defence.hypothesis.peaks, append(admin,args))

# Get parameters for optimisation
paramsP = optimisation.params.peaks(hypP)
paramsD = optimisation.params.peaks(hypD)

# reduce number of iterations for demonstration purposes
paramsP$control$itermax=25
paramsD$control$itermax=25

# Run optimisation
# n.steps and converge set for demonstration purposes
results = evaluate.peaks(paramsP, paramsD, n.steps=1, 
      converge=FALSE)

# generate output report
output.report.peaks(hypP,hypD,results)

## End(Not run)

likeLTD documentation built on May 1, 2019, 7:58 p.m.