Skip to content

Constrained Generalized Additive Model

2packages dependsuggested by 2
32.7Kdownloads / year
–test coverage
10/13flavors OK

Overview

About

A constrained generalized additive model is fitted by the cgam routine. Given a set of predictors, each of which may have a shape or order restrictions, the maximum likelihood estimator for the constrained generalized additive model is found using an iteratively re-weighted cone projection algorithm. The ShapeSelect routine chooses a subset of predictor variables and describes the component relationships with the response. For each predictor, the user needs only specify a set of possible shape or order restrictions. A model selection method chooses the shapes and orderings of the relationships as well as the variables. The cone information criterion (CIC) is used to select the best combination of variables and shapes. A genetic algorithm may be used when the set of possible models is large. In addition, the cgam routine implements a two-dimensional isotonic regression using warped-plane splines without additivity assumptions. It can also fit a convex or concave regression surface with triangle splines without additivity assumptions. See Liao X, Meyer MC (2019)doi:10.18637/jss.v089.i05 for more details.

Install

Health

CRAN checks
3NOTE10OK
Check messages
NOTEdependencies in R coder-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-devel-windows-x86_64

r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc

Base packages in Suggests/Enhances imported in NAMESPACE:
  ‘grDevices’ ‘graphics’ ‘utils’

r-devel-windows-x86_64

Base packages in Suggests/Enhances imported in NAMESPACE:
  'grDevices' 'graphics' 'utils'

CRAN check page ↗

Slowest check: 5.7 min · r-oldrel-windows-x86_64
Status changes
  • NOTE10 OK, 3 NOTENow
  • NOTE11 OK, 2 NOTE2026-09-12
  • OK13 OK2026-08-05
  • NOTE12 OK, 1 NOTE2026-08-01
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 1.33
READMENoVignettesNoNEWSNoCitation fileYes · cites a publicationWebsitenot declared in DESCRIPTION
Description cites a JSS article
Help pages
38
Examples that run
84%31 run in a plain check · 6 never run
Exported functions with examples
100%
Documented parameters
92%
Return-value docs
100%
Help pages citing references
82%

Downloads

32.7K
CRAN downloads in the past year
Rank #2,276 · ~89/day · ~2.7K/mo
Daily download trend is not available in this view yet.
3.2K30 days
7.4K90 days
32.7K1 year
Compare downloads with other packages →
Also on302 r2u16 autocran

Dependencies

Declared dependencies
13 external dependencies (excludes base and recommended)

Installing cgam adds 42 packages (23 with compiled code, 30 MB of source tarballs). Heaviest: ggplot2 6.0 MB, lme4 4.1 MB, nloptr 2.1 MB.

Depends (2)
R >= 4.3.0coneproj
LinkingTo (0)
none
Enhances (0)
none
Reverse dependencies
2direct
1indirect
Depends 1 · Imports 1
Suggested by 2
Depends, Imports or LinkingTo, most downloaded first
Suggests, most downloaded first

Datasets

People & History

People (2)
Author, Maintainer since 1.0 (2014)
Author · added in 1.18
Listed in earlier versions (1)
no longer listed · 1.0 to 1.17
Releases (34)

Pick two releases to compare their code metrics.

Show 32 earlier eventsHide 32 earlier events
  • R
    R 4.3.0 released · 2023-04-21
  • 1.20
    record
    2022-11-16 · diff ↗
  • 1.19
    record
    2022-10-04 · diff ↗
  • 1.18
    record
    2022-07-18 · diff ↗
  • R
    R 4.2.0 released · 2022-04-22
  • 1.17
    record
    2021-12-13 · diff ↗
  • R
    R 4.1.0 released · 2021-05-18
  • 1.16
    record
    2020-09-29 · diff ↗
  • R
    R 4.0.0 released · 2020-04-24
  • 1.15
    record
    2019-10-13 · diff ↗
  • 1.14
    record
    2019-05-01 · diff ↗
  • R
    R 3.6.0 released · 2019-04-26
  • 1.13
    record
    2019-04-23 · diff ↗
  • 1.12
    record
    2018-11-08 · diff ↗
  • 1.11
    record
    2018-06-28 · diff ↗ ·
    added 1 export
    cgamm
  • R
    R 3.5.0 released · 2018-04-23
  • 1.10
    record
    2018-04-11 · diff ↗
  • 1.9
    record
    2018-02-15 · diff ↗
  • 1.8
    record
    2017-10-02 · diff ↗
  • 1.7
    record
    2017-07-03 · diff ↗ ·
    removed 4 exports
    wps, ii, dd, di
    added 8 exports
    s.incr.incr, s.decr.decr, s.decr.incr, s.incr.decr, s.conv.conv, s.conc.conc, Ord, predict.cgam
  • R
    R 3.4.0 released · 2017-04-21
  • 1.6
    record
    2016-11-02 · diff ↗ ·
    added 4 exports
    ShapeSelect, shapes, in.or.out, best.fit
  • 1.5
    record
    2016-06-05 · diff ↗
  • R
    R 3.3.0 released · 2016-05-03
  • 1.4
    record
    2016-04-15 · diff ↗ ·
    added 4 exports
    wps, ii, dd, di
  • 1.3
    record
    2015-10-01 · diff ↗
  • R
    R 3.2.0 released · 2015-04-16
  • 1.2
    record
    2014-09-10 · diff ↗ ·
    added 10 exports
    s, s.incr, s.decr, s.conc, s.conv, s.incr.conc, s.incr.conv, s.decr.conc, s.decr.conv, plotpersp
  • 1.1
    record
    2014-04-17 · diff ↗
  • R
    R 3.1.0 released · 2014-04-10
  • 1.0
    record
    2014-03-05
  • R
    R 3.0.0 released · 2013-04-03

Package metadata

First published
2014-03-05
Total releases
34 / 12 yrs
License
GPL (>= 2) OSI
Minimum R
≥ 4.3.0
Bundled data
116 KB / 4 files
Download size
352 KB

Cite

Cite this package

Run in R for the authors' entry:

citation("cgam")

The package provides a citation file, so citation() returns the authors' own entry.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for cgam version 1.33 [Data set]. HJJB, LLC. Data release v2026-10-21. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-21, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy