Skip to content

Commit dc809fe

Browse files
20230207 - fix check build warnings/errors
1 parent fd5b105 commit dc809fe

14 files changed

Lines changed: 35 additions & 21 deletions

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: petersenlab
22
Type: Package
33
Title: Package of R Functions for the Petersen Lab
4-
Version: 0.1.2-9014
4+
Version: 0.1.2-9015
55
Authors@R: person("Isaac T.", "Petersen",
66
email = "isaac-t-petersen@uiowa.edu",
77
role = c("aut", "cre"),

NAMESPACE

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ export(write.aes)
7070
importFrom(Hmisc,rcorr)
7171
importFrom(RColorBrewer,brewer.pal)
7272
importFrom(digest,AES)
73-
importFrom(dplyr,"%>%")
7473
importFrom(dplyr,filter)
7574
importFrom(dplyr,group_by)
7675
importFrom(dplyr,mutate)
@@ -115,14 +114,24 @@ importFrom(psych,corr.p)
115114
importFrom(psych,partial.r)
116115
importFrom(reshape2,melt)
117116
importFrom(stats,anova)
117+
importFrom(stats,as.formula)
118+
importFrom(stats,coef)
119+
importFrom(stats,cor)
120+
importFrom(stats,cor.test)
118121
importFrom(stats,density)
119122
importFrom(stats,lm)
120123
importFrom(stats,lm.influence)
124+
importFrom(stats,loess)
121125
importFrom(stats,loess.control)
126+
importFrom(stats,logLik)
127+
importFrom(stats,median)
128+
importFrom(stats,na.exclude)
122129
importFrom(stats,na.omit)
130+
importFrom(stats,pchisq)
123131
importFrom(stats,pnorm)
124132
importFrom(stats,ppoints)
125133
importFrom(stats,predict)
134+
importFrom(stats,pt)
126135
importFrom(stats,qnorm)
127136
importFrom(stats,quantile)
128137
importFrom(stats,resid)

R/accuracyAtCutoff.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@
7878
#'
7979
#' @family accuracy
8080
#'
81-
#' @importFrom dplyr %>% mutate group_by summarise
81+
#' @importFrom dplyr mutate group_by summarise
8282
#' @importFrom ggplot2 cut_number
8383
#' @importFrom stringr str_replace_all str_split
8484
#' @importFrom stats qnorm na.omit
@@ -169,8 +169,8 @@ accuracyAtCutoff <- function(predicted, actual, cutoff, UH = NULL, UM = NULL, UC
169169

170170
bin <- NULL
171171

172-
calibrationTable <- mutate(data, bin = cut_number(predicted, n = bins)) %>%
173-
group_by(bin) %>%
172+
calibrationTable <- mutate(data, bin = cut_number(predicted, n = bins)) |>
173+
group_by(bin) |>
174174
summarise(n = length(predicted),
175175
meanPredicted = mean(predicted, na.rm = TRUE),
176176
meanObserved = mean(actual, na.rm = TRUE),

R/addCorrelationToScatterplot.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
#' @family correlations
2929
#'
3030
#' @importFrom graphics text
31-
#' @importFrom stats na.omit
31+
#' @importFrom stats na.omit median cor.test
3232
#'
3333
#' @export
3434
#'

R/equivalenceTest.R

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
#' @return p-value indicating whether to reject the null hypothesis that the
2424
#' model is a poor fit to the data.
2525
#'
26+
#' @importFrom stats pchisq
27+
#'
2628
#' @export
2729
#'
2830
#' @examples

R/hlm.R

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
#' @family mixedModel
1919
#'
2020
#' @importFrom nlme lme intervals getResponse
21+
#' @importFrom stats cor
2122
#'
2223
#' @export
2324
#'

R/imputationCombine.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#'
1818
#' @importFrom nlme fixef
1919
#' @importFrom mix mi.inference
20-
#' @importFrom stats na.omit
20+
#' @importFrom stats na.omit cor
2121
#'
2222
#' @export
2323
#'

R/imputationModelCompare.R

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@
1919
#'
2020
#' @family multipleImputation
2121
#'
22+
#' @importFrom stats logLik
23+
#'
2224
#' @export
2325
#'
2426
#' @examples

R/lmCombine.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#' @family multipleImputation
1717
#'
1818
#' @importFrom mix mi.inference
19-
#' @importFrom stats vcov lm
19+
#' @importFrom stats vcov lm coef
2020
#'
2121
#' @export
2222
#'

R/make_esem_model.R

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
#'
2525
#' @family lavaan
2626
#'
27-
#' @importFrom dplyr %>% filter select rename
27+
#' @importFrom dplyr filter select rename
2828
#' @importFrom lavaan sem parameterEstimates
2929
#'
3030
#' @export
@@ -65,10 +65,10 @@
6565
#' esem_loadings <- lavaan::parameterEstimates(
6666
#' efa_fit,
6767
#' standardized = TRUE
68-
#' ) %>%
69-
#' filter(efa == "efa1") %>%
70-
#' select(lhs, rhs, est) %>%
71-
#' rename(item = rhs, latent = lhs, loading = est)
68+
#' ) |>
69+
#' dplyr::filter(efa == "efa1") |>
70+
#' dplyr::select(lhs, rhs, est) |>
71+
#' dplyr::rename(item = rhs, latent = lhs, loading = est)
7272
#'
7373
#' # Specify Anchor Item for Each Latent Factor
7474
#' anchors <- c(f1 = "x3", f2 = "x5", f3 = "x7")

0 commit comments

Comments
 (0)