Skip to contents

Fits an adjacent-category logit regression for ordinal responses (via fast_adjacent_category_logit_cpp — see that page for the full model, an alternative ordinal parameterization to the cumulative-logit proportional-odds model) using the treatment indicator and, optionally, all recorded covariates as predictors. This is a full-likelihood class (likelihood_tier = "full") supporting score, gradient, and likelihood-ratio tests, plus parametric likelihood-ratio bootstrap calibration, in addition to Wald and resampling-based inference. Bayesian-bootstrap inference is temporarily unavailable because the current non-uniform weighted hook fits a cumulative-logit surrogate rather than the adjacent-category likelihood. It will remain disabled until the native weighted adjacent-category backend described in the package implementation plan lands.

Super class

Inference -> InferenceOrdinalAdjCatLogitRegr

Methods

+ inherited public methods from Inference


InferenceOrdinalAdjCatLogitRegr$set_custom_randomization_statistic_function()

Usage

InferenceOrdinalAdjCatLogitRegr$set_custom_randomization_statistic_function(
  custom_randomization_statistic_function
)


InferenceOrdinalAdjCatLogitRegr$set_custom_randomization_statistic_cpp()

Usage

InferenceOrdinalAdjCatLogitRegr$set_custom_randomization_statistic_cpp(fn)


InferenceOrdinalAdjCatLogitRegr$approximate_randomization_distribution_beta_hat_T()

Usage

InferenceOrdinalAdjCatLogitRegr$approximate_randomization_distribution_beta_hat_T(
  r = 501,
  delta = 0,
  transform_responses = "none",
  show_progress = TRUE,
  permutations = NULL,
  debug = FALSE,
  zero_one_logit_clamp = .Machine$double.eps
)


InferenceOrdinalAdjCatLogitRegr$supports_rand_pval_for_incidence()

Usage

InferenceOrdinalAdjCatLogitRegr$supports_rand_pval_for_incidence()


InferenceOrdinalAdjCatLogitRegr$compute_rand_two_sided_pval()

Usage

InferenceOrdinalAdjCatLogitRegr$compute_rand_two_sided_pval(
  r = 501,
  delta = 0,
  transform_responses = "none",
  na.rm = TRUE,
  show_progress = TRUE,
  permutations = NULL,
  zero_one_logit_clamp = .Machine$double.eps
)


InferenceOrdinalAdjCatLogitRegr$clone()

The objects of this class are cloneable with this method.

Usage

InferenceOrdinalAdjCatLogitRegr$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Examples

# \donttest{
seq_des = DesignSeqOneByOneBernoulli$new(n = 10, response_type = 'ordinal')
for (i in 1:10) {
  seq_des$add_one_subject_to_experiment_and_assign(data.frame(x1 = rnorm(1)))
}
seq_des$add_all_subject_responses(sample(1:4, 10, replace = TRUE))
inf = InferenceOrdinalAdjCatLogitRegr$new(seq_des)
inf$compute_estimate()
#> [1] -0.9086307
# }