Skip to content

Commit

Permalink
Documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
EdwinKipruto committed Nov 10, 2023
1 parent 1a38e13 commit 826f22a
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 22 deletions.
3 changes: 0 additions & 3 deletions CRAN-SUBMISSION

This file was deleted.

8 changes: 4 additions & 4 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ Suggests:
formatR,
patchwork,
spelling
Description: Algorithm to select variables and functional forms through
Description: Algorithm to select variables and functional forms simultaneously through
fractional polynomials in regression models (Generalized linear models
and Cox). In addition, it has the ability to model a sigmoid relationship
between x and an outcome variable y using the approximate cumulative
distribution transformation proposed by "Royston" in 2014.
and Cox models). In addition, it can model a 'sigmoid' relationship
between variable x and an outcome variable y using the approximate cumulative
distribution transformation- something that a standard fractional polynomial function cannot do.
License: GPL-3 + file LICENSE
URL: https://github.com/EdwinKipruto/mfp2
BugReports: https://github.com/EdwinKipruto/mfp2/issues
Expand Down
2 changes: 0 additions & 2 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# mfp2 1.0.0

# mfp2 0.2

* Initial CRAN submission.
4 changes: 0 additions & 4 deletions R/mfp2.R
Original file line number Diff line number Diff line change
Expand Up @@ -338,8 +338,6 @@
#' fit1 = mfp2(x, y, verbose = FALSE)
#' fit1$fp_terms
#' fracplot(fit1) # generate plots
#' coef(fit1)
#' print(fit1)
#' summary(fit1)
#' # formula interface
#' fit1b = mfp2(lpsa ~ fp(age) + fp(svi, df = 1) + fp(pgg45) + fp(cavol) + fp(weight) +
Expand All @@ -351,7 +349,6 @@
#' yy <- as.vector(pima$y)
#' fit2 <- mfp2(xx, yy, family = "binomial", verbose = FALSE)
#' fit2$fp_terms
#' fracplot(fit2)
#'
#' # Cox regression model
#' data("gbsg")
Expand All @@ -362,7 +359,6 @@
#' # fit mfp and keep hormon in the model
#' fit3 <- mfp2(xd, yd, family = "cox", keep = "hormon", verbose = FALSE)
#' fit3$fp_terms
#' fracplot(fit3)
#'
#' @return
#' `mfp2()` returns an object of class inheriting from `glm` or `copxh`,
Expand Down
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,17 @@
extensions. It allows the selection of variables and functional forms when
modelling the relationship of a data matrix `x` and some outcome `y`. Currently
supports generalized linear models and Cox proportional hazards models.
It also has the ability to model a sigmoid relationship between x and an outcome variable y
using approximate cumulative distribution transformation- something that a standard fractional
polynomial function cannot achieve (Royston 2014).

## Compatibility with existing software packages

`mfp2` closely emulates the functionality of the [`mfp` package in
stata].
`mfp2` closely emulates the functionality of the `mfp` package in
Stata.

It augments the functionality of the existing [`mfp` R
package]by:
It augments the functionality of the existing `mfp` R
package by:

- a matrix and a formula interface for input
- sigmoid transformations via the approximate cumulative distribution (ACD)
Expand Down
2 changes: 1 addition & 1 deletion cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## R CMD check results

0 errors | 0 warnings | 4 note
0 errors | 0 warnings | 1 note

* This is a new release.
4 changes: 0 additions & 4 deletions man/mfp2.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 826f22a

Please sign in to comment.