Science Score: 36.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
✓Committers with academic emails
1 of 12 committers (8.3%) from academic institutions -
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (10.4%) to scientific vocabulary
Keywords from Contributors
Repository
An R package for generalised survival models
Statistics
- Stars: 27
- Watchers: 7
- Forks: 12
- Open Issues: 5
- Releases: 6
Metadata Files
README.md
rstpm2: An R package for link-based survival models
NOTE: versions 1.4.1 and 1.4.2 of rstpm2 included a critical bug in the predict function for type in "hr", "hdiff", "meanhr" or "marghr".
Introduction
This package provides link-based survival models that extend the Royston-Parmar models, a family of flexible parametric models. There are two main classes included in this package:
A. The class stpm2 is an R version of stpm2 in Stata with some extensions, including:
Multiple links (log-log, -probit, -logit);
Left truncation and right censoring (with experimental support for interval censoring);
Relative survival;
Cure models (where we introduce the
nsxsmoother, which extends thenssmoother);Predictions for survival, hazards, survival differences, hazard differences, mean survival, etc;
Functional forms can be represented in regression splines or other parametric forms;
The smoothers for time can use any transformation of time, including no transformation or log(time).
B. Another class pstpm2 is the implementation of the penalised models and corresponding penalized likelihood estimation methods. The main aim is to represent another way to deal with non-proportional hazards and adjust for potential continuous confounders in functional forms, not limited to proportional hazards and linear effect forms for all covariates. Functional forms can be represented in penalized regression splines (all mgcv smoothers ) or other parametric forms.
Some examples
The default for the parametric model is to use the Royston Parmar model, which uses a natural spline for the transformed baseline for log(time) with a log-log link.
require(rstpm2)
data(brcancer)
fit <- stpm2(Surv(rectime,censrec==1)~hormon,data=brcancer,df=3)
plot(fit,newdata=data.frame(hormon=0),type="hazard")

The default for the penalised model is similar, using a thin-plate spline for the transformed baseline for log(time) with a log-log link. The advantage of the penalised model is that there is no need to specify the knots or degrees of freedom for the baseline smoother.
fit <- pstpm2(Surv(rectime,censrec==1)~hormon,data=brcancer)
plot(fit,newdata=data.frame(hormon=0),type="hazard")

Owner
- Login: mclements
- Kind: user
- Location: Stockholm
- Company: Karolinska Institutet
- Repositories: 15
- Profile: https://github.com/mclements
GitHub Events
Total
- Issues event: 6
- Issue comment event: 5
- Push event: 8
- Pull request event: 2
Last Year
- Issues event: 6
- Issue comment event: 5
- Push event: 8
- Pull request event: 2
Committers
Last synced: about 1 year ago
Top Committers
| Name | Commits | |
|---|---|---|
| Mark Clements | m****s@k****e | 724 |
| Xingrong Liu | x****u@k****e | 15 |
| unknown | l****n@D****e | 7 |
| Benjamin Christoffersen | b****d@g****m | 6 |
| bakynkozhayev | b****v@k****e | 3 |
| Lasse Hjort Jakobsen | s****y@a****k | 3 |
| unknown | l****n@D****e | 2 |
| Liu Xingrong | l****n@m****e | 2 |
| Tomas Kalibera | t****a@g****m | 1 |
| Dirk Eddelbuettel | e****d@d****g | 1 |
| bakynkozhayev | b****v@n****z | 1 |
| Mark Clements | m****s@L****l | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 10 months ago
All Time
- Total issues: 33
- Total pull requests: 4
- Average time to close issues: over 1 year
- Average time to close pull requests: about 13 hours
- Total issue authors: 18
- Total pull request authors: 3
- Average comments per issue: 2.12
- Average comments per pull request: 1.25
- Merged pull requests: 4
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 3
- Pull requests: 1
- Average time to close issues: N/A
- Average time to close pull requests: 2 days
- Issue authors: 2
- Pull request authors: 1
- Average comments per issue: 0.67
- Average comments per pull request: 4.0
- Merged pull requests: 1
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- alexploner (5)
- ellessenne (4)
- enochytchen (4)
- aghaynes (3)
- Luigi-Annic (2)
- markdanese (2)
- LasseHjort (2)
- ghost (2)
- entjos (2)
- anddis (1)
- mikesweeting (1)
- NickSauve (1)
- LivUllmann (1)
- RobertReynolds1 (1)
- MoserGitHub (1)
Pull Request Authors
- boennecd (2)
- kalibera (2)
- eddelbuettel (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 2
-
Total downloads:
- cran 9,982 last-month
- Total docker downloads: 43,526
-
Total dependent packages: 15
(may contain duplicates) -
Total dependent repositories: 11
(may contain duplicates) - Total versions: 33
- Total maintainers: 1
cran.r-project.org: rstpm2
Smooth Survival Models, Including Generalized Survival Models
- Homepage: https://github.com/mclements/rstpm2
- Documentation: http://cran.r-project.org/web/packages/rstpm2/rstpm2.pdf
- License: GPL-2 | GPL-3
-
Latest release: 1.7.0
published 10 months ago
Rankings
Maintainers (1)
conda-forge.org: r-rstpm2
- Homepage: http://github.com/mclements/rstpm2
- License: GPL-2.0-or-later
-
Latest release: 1.5.8
published over 3 years ago
Rankings
Dependencies
- R >= 3.0.2 depends
- methods * depends
- splines * depends
- survival * depends
- Rcpp >= 0.10.2 imports
- bbmle >= 1.0.20 imports
- deSolve * imports
- fastGHQuad * imports
- graphics * imports
- mgcv * imports
- parallel * imports
- stats * imports
- utils * imports
- eha * suggests
- flexsurv * suggests
- ggplot2 * suggests
- lattice * suggests
- mstate * suggests
- readstata13 * suggests
- scales * suggests
- survPen * suggests
- testthat * suggests
- timereg * suggests