Smooth Effects on Response Penalty for CLM

Implements a regularization method for cumulative link models using the Smooth-Effect-on-Response Penalty (SERP). This method allows flexible modeling of ordinal data by enabling a smooth transition from a general cumulative link model to a simplified version of the same model. As the tuning parameter increases from zero to infinity, the subject-specific effects for each variable converge to a single global effect. The approach addresses common issues in cumulative link models, such as parameter unidentifiability and numerical instability, by maximizing a penalized log-likelihood instead of the standard non-penalized version. Fitting is performed using a modified Newton's method. Additionally, the package includes various model performance metrics and descriptive tools. For details on the implemented penalty method, see Ugba (2021) and Ugba et al. (2021) .


serp

Project Status: Active – The project has reached a stable, usablestate and is beingactivelydeveloped Codecov testcoverage Total Downloads CRANstatus DOI AppVeyor buildstatus license R buildstatus

Overview

The serp R package fits cumulative link models (CLMs) with the smooth-effect-on-response penalty (SERP). The cumulative model developed by McCullagh (1980) is probably the most frequently used ordinal model in empirical studies. However, the stochastic ordering property of the general form of the model poses a very serious challenge in most empirical applications of the model. For instance, unstable likelihoods with ill-conditioned parameter space are frequently encountered during the iterative process. serp implements a unique regularization method for CLMs that provides the means of smoothing the adjacent categories in the model. At extreme shrinkage, SERP causes all subject-specific effects associated with each variable in the model to shrink towards unique global effects. Fitting is done using a modified Newton’s method. Several standard model performance and descriptive methods are also available. See Ugba, 2021, Ugba et al., 2021 and Tutz and Gertheiss, 2016 for further details on the implemented penalty.

Example

Consider the cumulative logit model of the wine dataset, where the rating of wine bitterness is predicted with the two treatment factors, temperature and contact.

## The unpenalized non-proportional odds model returns unbounded estimates, hence,
## not fully identifiable.
f1 <- serp(rating ~ temp + contact, slope = "unparallel",
           reverse = TRUE, link = "logit", data = wine)
coef(f1)
## The penalized non-proportional odds model with a user-supplied lambda gives 
## a fully identified model having bounded estimates. A suitable tuning criterion
## could as well be used to select lambda (e.g., aic or cv) 
f2 <- serp(rating ~ temp + contact, slope = "penalize",
           link = "logit", reverse = TRUE, tuneMethod = "user",
           lambda = 1e1 ,data = wine)
coef(f2)
## A penalized partial proportional odds model with one variable set to 
## global effect is also possible.
f3 <- serp(rating ~ temp + contact, slope = "penalize",
           reverse = TRUE, link = "logit", tuneMethod = "user",
           lambda = 2e1, globalEff = ~ temp, data = wine)
coef(f3)
## The unpenalized proportional odds model with constrained estimates. 
## Under estreme shrinkage, estimates in f2 equal those in this model.  
f4 <-  serp(rating ~ temp + contact, slope = "parallel",
            reverse = FALSE, link = "logit", data = wine)
summary(f4)

Installation and Use

Before installing serp, it is encouraged to have a recent version of R installed. The released version of serp can be installed from CRAN with:

install.packages("serp")

or the development version from GitHub with:

if (!require("devtools")) install.packages("devtools")
devtools::install_github("ejikeugba/serp")

Load serp into R environment with:

library(serp)

Community Guidelines

Pull requests are welcomed! Please submit your contributions to serp through the list of Pull Requests, following the contributing guidelines. To report issues and/or seek support, please file a new ticket in the issue tracker, and expect a feedback ASAP!

Code of Conduct

Please note that serp is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.

References

McCullagh, P. (1980). Regression Models for Ordinal Data. Journal of the Royal Statistical Society. Series B (Methodological), 42, 109-142. https://doi.org/10.1111/j.2517-6161.1980.tb01109.x

Randall, J (1989). The analysis of sensory data by generalized linear model. Biometrical Journal, 31, 781–793. https://doi.org/10.1002/bimj.4710310703

Tutz, G. and Gertheiss, J. (2016). Regularized Regression for Categorical Data (With Discussion and Rejoinder). Statistical Modelling, 16, 161-260. https://doi.org/10.1177/1471082X16642560

Ugba, E. R., Mörlein, D. and Gertheiss, J. (2021). Smoothing in Ordinal Regression: An Application to Sensory Data. Stats, 4, 616–633. https://doi.org/10.3390/stats4030037

Ugba, E. R. (2021). serp: An R package for smoothing in ordinal regression Journal of Open Source Software, 6(66), 3705. https://doi.org/10.21105/joss.03705

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("serp")

0.2.5 by Ejike R. Ugba, 2 years ago


https://github.com/ejikeugba/serp


Report a bug at https://github.com/ejikeugba/serp/issues


Browse source code at https://github.com/cran/serp


Authors: Ejike R. Ugba [aut, cre, cph]


Documentation:   PDF Manual  


GPL-2 license


Imports ordinal, crayon, stats

Suggests covr, testthat, tibble, vctrs, pkgdown, VGAM


Suggested by gofcat, insight, parameters.


See at CRAN