Summarise and plot sampling effort for epidermal traits

subsampling_summary(df, traits, thresholdvalue = 0.2, number.of.bins = 6)

Arguments

df

A data.frame of the type output by subsample_epidermal_traits

traits

Character vector of the traits to summarise.

thresholdvalue

Numeric. Desired threshold for sample variation. Defaults to 0.2.

number.of.bins

Numeric. How many bins should be used to summarise samples? Recommended to use the same number of bins as values of k in subsample_epidermal_traits.

Value

A list of length 2: the first element (a list) contains the ggplot objects and the second (also a list) contains summarised data.

Examples

if (FALSE) {
#This example takes quite a while to run - see vignette for more details

sampled <-  subsample_epidermal_traits(traits1.1, n.runs = 100,
k.cells = c(100,150,200,250,300,350,400),
scaling =globalSDs,
trait.subset = reliable_traits)

summ <- subsampling_summary(sampled,
                           traits=c("stomzone.area.median" ,
                                    "stomatal.index",
                                    "stomzone.undulation.amp.median",
                                     "pavezone.undulation.amp.median"))
}