decision_highCMC_identifyHighCMCThetas: Classify theta values in CMC-theta distribution as having...

Description Usage Arguments Value Note Examples

View source: R/decision.R

Description

Classify theta values in CMC-theta distribution as having "High" or "Low" CMC candidate counts

Usage

1
decision_highCMC_identifyHighCMCThetas(cmcThetaDistrib, tau = 1)

Arguments

cmcThetaDistrib

output of the decision_highCMC_cmcThetaDistrib function

tau

constant used to define a "high" CMC count. This number is subtracted from the maximum CMC count achieved in the CMC-theta distribution. Theta values with CMC counts above this value are considered to have "high" CMC counts.

Value

A vector of the same length as the input containing "High" or "Low" classification based on whether the associated theta value has a High CMC Candidate count.

Note

This function is a helper internally called in the decision_CMC function. It is exported to be used as a diagnostic tool for the High CMC method

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
## Not run: 
data(fadul1.1_processed,fadul1.2_processed)

comparisonDF <- purrr::map_dfr(seq(-30,30,by = 3),
                              ~ comparison_allTogether(fadul1.1_processed,
                                                       fadul1.2_processed,
                                                       theta = .))

highCMCthetas <- comparisonDF %>%
dplyr::mutate(cmcThetaDistribClassif = decision_highCMC_cmcThetaDistrib(cellIndex = cellIndex,
                                                                 x = x,
                                                                 y = y,
                                                                 theta = theta,
                                                                 corr = pairwiseCompCor)) %>%
decision_highCMC_identifyHighCMCThetas(tau = 1)


highCMCthetas %>%
dplyr::filter(cmcThetaDistribClassif == "CMC Candidate") %>%
ggplot2::ggplot(ggplot2::aes(x = theta,fill = thetaCMCIdentif)) +
ggplot2::geom_bar(stat = "count")

## End(Not run)

cmcR documentation built on April 5, 2021, 5:09 p.m.