Skip to content

MASS

7.3-66Package record

Support Functions and Datasets for Venables and Ripley's MASS

2,178packages dependsuggested by 796
2.1Mdownloads / year
35.8%test coverage
12/13flavors OK

Overview

About

Functions and datasets to support Venables and Ripley, "Modern Applied Statistics with S" (4th edition, 2002).

Install

Health

CRAN checks
1ERROR12OK
Check messages
ERRORexamplesr-devel-linux-x86_64-debian-gcc
Running examples in ‘MASS-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: motors
> ### Title: Accelerated Life Testing of Motorettes
> ### Aliases: motors
> ### Keywords: datasets
> 
> ### ** Examples
> 
> library(survival)
> plot(survfit(Surv(time, cens) ~ factor(temp), motors), conf.int = FALSE)
> # fit Weibull model
> motor.wei <- survreg(Surv(time, cens) ~ temp, motors)
> ## IGNORE_RDIFF_BEGIN
> summary(motor.wei)

Call:
survreg(formula = Surv(time, cens) ~ temp, data = motors)
               Value Std. Error     z       p
(Intercept) 16.31852    0.62296  26.2 < 2e-16
temp        -0.04531    0.00319 -14.2 < 2e-16
Log(scale)  -1.09564    0.21480  -5.1 3.4e-07

Scale= 0.334 

Weibull distribution
Loglik(model)= -147.4   Loglik(intercept only)= -169.5
	Chisq= 44.32 on 1 degrees of freedom, p= 2.8e-11 
Number of Newton-Raphson Iterations: 8 
n= 40 

> ## IGNORE_RDIFF_END
> # and predict at 130C
> unlist(predict(motor.wei, data.frame(temp=130), se.fit = TRUE))
   fit.1 se.fit.1 
33813.06  7506.36 
> 
> motor.cox <- coxph(Surv(time, cens) ~ temp, motors)
> summary(motor.cox)
Call:
coxph(formula = Surv(time, cens) ~ temp, data = motors)

  n= 40, number of events= 17 

        coef exp(coef) se(coef)     z Pr(>|z|)    
temp 0.09185   1.09620  0.02736 3.358 0.000786 ***
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

     exp(coef) exp(-coef) lower .95 upper .95
temp     1.096     0.9122     1.039     1.157

Concordance= 0.84  (se = 0.035 )
Likelihood ratio test= 25.56  on 1 df,   p=4e-07
Wald test            = 11.27  on 1 df,   p=8e-04
Score (logrank) test = 22.73  on 1 df,   p=2e-06

> # predict at temperature 200
> plot(survfit(motor.cox, newdata = data.frame(temp=200),
+      conf.type = "log-log"))
Error in a$specials[[i]] : subscript out of bounds
Calls: plot ... survfit.coxph -> model.matrix.coxph -> delete.response -> off
Execution halted

CRAN check page ↗

Slowest check: 4.2 min · r-devel-windows-x86_64
Status changes
  • ERROR12 OK, 1 ERROR2026-10-24
  • OK13 OK2026-10-20
  • NOTE12 OK, 1 NOTE2026-10-17
  • OK13 OK2026-09-08
  • ERROR12 OK, 1 ERROR2026-09-07
Show 19 earlier changesHide 19 earlier changes
  • OK13 OK2026-09-04
  • NOTE12 OK, 1 NOTE2026-08-31
  • OK13 OK2026-08-05
  • NOTE12 OK, 1 NOTE2026-08-01
  • OK13 OK2026-07-19
  • NOTE11 OK, 2 NOTE2026-07-16
  • OK13 OK2026-06-27
  • ERROR12 OK, 1 ERROR2026-06-24
  • OK13 OK2026-05-11
  • ERROR12 OK, 1 ERROR2026-05-10
  • OK13 OK2026-04-30
  • ERROR12 OK, 1 ERROR2026-04-28
  • OK14 OK2026-04-24
  • ERROR13 OK, 1 ERROR2026-04-22
  • OK14 OK2026-04-18
  • ERROR13 OK, 1 ERROR2026-04-16
  • OK14 OK2026-03-31
  • ERROR13 OK, 1 ERROR2026-03-28
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 7.3-66
READMENoVignettesNoNEWSYes · 33% structuredCitation fileYes · cites a publicationWebsiteYes
Help pages
155 (2 internal)
Examples that run
100%79 run in a plain check
Exported functions with examples
77%
Documented parameters
88%
Return-value docs
91%
Help pages citing references
82%

Downloads

2.1M
CRAN downloads in the past year
Rank #221 · ~5.7K/day · ~173.5K/mo
Daily download trend is not available in this view yet.
245.9K30 days
641.5K90 days
2.1M1 year
Compare downloads with other packages →
Also on102.4K r2u5.1K autocran1.5M conda_forge5.2K c2d4u

Dependencies

Declared dependencies
0 external dependencies (excludes base and recommended)

Installing MASS adds no packages beyond those that come with R.

Depends (5)
R >= 4.4.0grDevicesgraphicsstatsutils
Imports (1)
methods
LinkingTo (0)
none
Suggests (4)
latticenlmennetsurvival
Enhances (0)
none

Datasets

People & History

People (6)
Author, Maintainer since 7.3-0 (2009), Copyright holder
Author, Copyright holder · added in 7.3-20
Contributor
Contributor · added in 7.3-17
support functions for polr
Translator · added in 7.3-17
partial port ca 1998
Translator
partial port ca 1998
Listed in earlier versions (4)
Show 4 peopleHide 4 people
no longer listed · 7.3-0 to 7.3-8
Venables
no longer listed · 7.3-0 to 7.3-16
Albrecht Gebhardt around 1998.
no longer listed · 7.3-9 to 7.3-16
Douglas M.
no longer listed · 7.3-27 to 7.3-66
Releases (78)

Pick two releases to compare their code metrics.

Show 83 earlier eventsHide 83 earlier events

Package metadata

First published
2009-05-08
Total releases
78 / 17 yrs
License
GPL-2 | GPL-3 OSI
Minimum R
≥ 4.4.0
Bundled data
166 KB / 87 files
Download size
498 KB

Cite

Cite this package

Run in R for the authors' entry:

citation("MASS")

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 MASS version 7.3-66 [Data set]. HJJB, LLC. Data release v2026-10-24. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-24, 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