| PBclassifier | R Documentation |
Estimates a monotone binary classification rule for multivariate features
using a projective Bayes classifier. The classifier is obtained by projecting
an unconstrained nonparametric Bayes estimator onto the partial ordering
subspace defined by the assumption that the outcome probability is
nondecreasing in each feature. The projection is computed using a recursive
sequential update algorithm that yields the exact Bayes solution maximizing
the posterior gain. Both a down-up ("DU") and an up-down ("UD")
algorithm are available.
PBclassifier(X, y, method = "DU", a0 = 0.5, b0 = 0.5, t0 = 0.5)
X |
a numeric matrix of observed feature combinations, one row per observation, where repeated rows are expected. Each column represents a feature (e.g., a dose component or experimental factor) and each row represents the feature combination observed for one unit. |
y |
a binary numeric vector of length |
method |
a character string specifying the search strategy for finding
the optimal monotone classification, either |
a0 |
a positive numeric value specifying the shape1 hyperparameter of the Beta prior in the Beta-Binomial conjugate model. Defaults to 0.5 (Jeffreys prior). |
b0 |
a positive numeric value specifying the shape2 hyperparameter of the Beta prior in the Beta-Binomial conjugate model. Defaults to 0.5 (Jeffreys prior). |
t0 |
a numeric value in (0,1) specifying the threshold on the response rate used to classify each feature combination as event or no-event. Defaults to 0.5. |
A list of class "pbc" containing the following components:
a numeric matrix of unique feature combinations
a numeric vector of observation counts at each feature combination
a numeric vector of event counts at each feature combination
a binary numeric vector of the optimal monotone classification for each feature combination (1 = event, 0 = no event)
a numeric vector of posterior probabilities that the true response
rate exceeds t0 at each feature combination
the log posterior probability of the optimal classification
Cheung YK, Diaz KM. Monotone response surface of multi-factor condition: estimation and Bayes classifiers. J R Stat Soc Series B Stat Methodol. 2023 Apr;85(2):497-522. doi: 10.1093/jrsssb/qkad014. Epub 2023 Mar 22. PMID: 38464683; PMCID: PMC10919322.
Cheung YK, Kuhn L. Evaluating multiplex diagnostic test using partially ordered Bayes classifier. Ann Appl Stat. In press.
A <- as.matrix(expand.grid(rep(list(0:1), 6)))
set.seed(2025)
X <- A[sample(nrow(A),size=500, replace = TRUE),]
y <- as.numeric(rowSums(X)>=3)
PBclassifier(X,y)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.