Skip to content

Commit

Permalink
Merge pull request #4 from remlapmot/r-4-2-0-check
Browse files Browse the repository at this point in the history
Fix R CMD check note under R 4.2.0
  • Loading branch information
remlapmot authored Apr 28, 2022
2 parents c401054 + d26ddeb commit 763bc9b
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 27 deletions.
47 changes: 21 additions & 26 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,31 +1,26 @@
Package: OneSampleMR
Title: One Sample Mendelian Randomization and Instrumental Variable Analyses
Version: 0.1.0
Authors@R:
c(person(given = "Tom",
family = "Palmer",
role = c("aut", "cre"),
email = "[email protected]",
comment = c(ORCID = "0000-0003-4655-4511")),
person(given = "Wes",
family = "Spiller",
role = "aut",
email = "[email protected]",
comment = c(ORCID = "0000-0002-8169-5531")),
person(given = "Eleanor",
family = "Sanderson",
role = "aut",
email = "[email protected]",
comment = c(ORCID = "0000-0001-5188-5775")))
Description: Useful functions for one-sample (individual level data) Mendelian randomization and
instrumental variable analyses. The package includes implementations of; the Sanderson and
Windmeijer (2016) <doi:10.1016/j.jeconom.2015.06.004> conditional F-statistic, the
multiplicative structural mean model Hernán and Robins (2006)
<doi:10.1097/01.ede.0000222409.00878.37>, and two-stage predictor substitution and two-stage
residual inclusion estimators explained by Terza et al. (2008)
<doi:10.1016/j.jhealeco.2007.09.009>.
Title: One Sample Mendelian Randomization and Instrumental Variable
Analyses
Version: 0.1.1
Authors@R: c(
person("Tom", "Palmer", , "[email protected]", role = c("aut", "cre"),
comment = c(ORCID = "0000-0003-4655-4511")),
person("Wes", "Spiller", , "[email protected]", role = "aut",
comment = c(ORCID = "0000-0002-8169-5531")),
person("Eleanor", "Sanderson", , "[email protected]", role = "aut",
comment = c(ORCID = "0000-0001-5188-5775"))
)
Description: Useful functions for one-sample (individual level data)
Mendelian randomization and instrumental variable analyses. The
package includes implementations of; the Sanderson and Windmeijer
(2016) <doi:10.1016/j.jeconom.2015.06.004> conditional F-statistic,
the multiplicative structural mean model Hernán and Robins (2006)
<doi:10.1097/01.ede.0000222409.00878.37>, and two-stage predictor
substitution and two-stage residual inclusion estimators explained by
Terza et al. (2008) <doi:10.1016/j.jhealeco.2007.09.009>.
License: GPL (>= 3)
URL: https://github.com/remlapmot/OneSampleMR
URL: https://github.com/remlapmot/OneSampleMR,
https://remlapmot.github.io/OneSampleMR/
BugReports: https://github.com/remlapmot/OneSampleMR/issues/
Depends:
R (>= 3.6.0)
Expand Down
4 changes: 4 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# OneSampleMR 0.1.1

* Fix an issue causing an R CMD check note in R 4.2.0

# OneSampleMR 0.1.0

* Initial submission to CRAN
2 changes: 1 addition & 1 deletion R/fsw.R
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ fsw.ivreg <- function(object) {
"ivreg(y ~ log(x1) + x2 | z1 + z2 + z3)",
"please create dat$logx1 = log(x1) in your data.frame",
"and fit ivreg(y ~ logx1 + x2 | z1 + z2 + z3).")
if (class(condmod) == "try-error") stop(condmoderrmsg)
if (inherits(condmod, "try-error")) stop(condmoderrmsg)
condres <- condmod$residuals
if (nexogenous > 0) {
resfor <- as.formula(paste("condres", "~", instrplus, "+", exogplus))
Expand Down

0 comments on commit 763bc9b

Please sign in to comment.