dptriml_s: Automatically trim a list of density profiles on the starting side
Description
Calls dptrim on a list of dp objects and returns a list of
trimmed objects. If automatic detection fails, the dp objects are
not trimmed. Can be run in parallel on multiple cores, this speeds
up the trimming process significantly. Only trims the starting
side, see dptriml for trimming both side simultaneously.
Usage
dptriml_s(dp.list, rreport = FALSE, cl = 1, ...)
Arguments
dp.list
A list of dp objects, see dpload
rreport
Return an embedded report on automatic trim success,
mandatory when using correct_failures to manually pick
starting/ending.
cl
Number of cores to run the trimming in parallel, passed
through to pbapply.
...
Parameters minseglen, span and nroll, will get passed through
to dpdetect_s, adjust when profile resolution is not 1/100 of a millimeter.
Value
A list of trimmed dp objects. When rreport = TRUE, it
return a two-item list of (i) trimmed dp objects and (ii)
trimming report data frame.
# NOT RUN {## load several dp filesdp.list <- dpload(dp.directory = system.file("extdata", package = "densitr"))
## trim the measurementsdp.trimmed <- dptriml_s(dp.list)
# }