Skip to content

Commit aef399b

Browse files
committed
fixed import issues
1 parent 6740d52 commit aef399b

5 files changed

Lines changed: 11 additions & 7 deletions

File tree

DESCRIPTION

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ Imports:
7070
data.table,
7171
methods,
7272
dplyr,
73+
purrr,
7374
assertthat,
7475
cli
7576
Suggests:
@@ -85,4 +86,4 @@ Suggests:
8586
DSLite
8687
Encoding: UTF-8
8788
Language: en-GB
88-
Config/roxygen2/version: 8.0.0
89+
Config/roxygen2/version: 8.0.0.9000

NAMESPACE

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,6 @@ export(ds.var)
121121
export(ds.vectorCalc)
122122
export(subsetHelper)
123123
import(DSI)
124-
import(data.table)
125-
import(dplyr)
126124
importFrom(DSI,datashield.aggregate)
127125
importFrom(DSI,datashield.assign)
128126
importFrom(assertthat,assert_that)
@@ -136,6 +134,13 @@ importFrom(cli,cli_li)
136134
importFrom(cli,cli_ol)
137135
importFrom(cli,cli_text)
138136
importFrom(cli,cli_ul)
137+
importFrom(data.table,.SD)
138+
importFrom(dplyr,"%>%")
139+
importFrom(dplyr,all_of)
140+
importFrom(dplyr,bind_rows)
141+
importFrom(dplyr,case_when)
142+
importFrom(dplyr,row_number)
143+
importFrom(dplyr,where)
139144
importFrom(purrr,map)
140145
importFrom(purrr,map_lgl)
141146
importFrom(purrr,pmap)

R/computeWeightedMeans.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#' @param by character vector of the columns to group by
1212
#' @return Returns a data table object with computed weighted means.
1313
#'
14-
#' @import data.table
14+
#' @importFrom data.table .SD
1515
#' @importFrom stats as.formula na.omit ts weighted.mean
1616
#' @keywords internal
1717
computeWeightedMeans <- function(data_table, variables, weight, by) {

R/ds.bp_standards.R

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
#' blood pressure in children and adolescents:
2727
#' https://www.nhlbi.nih.gov/sites/default/files/media/docs/hbp_ped.pdf
2828
#' @author Demetris Avraam for DataSHIELD Development Team
29-
#' @import data.table
3029
#' @export
3130
ds.bp_standards <- function(sex=NULL, age=NULL, height=NULL, bp=NULL, systolic=TRUE,
3231
newobj=NULL, datasources=NULL){

R/ds.standardiseDf.R

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ ds.standardiseDf <- function(df.name = NULL, newobj = NULL, fix_class = "ask", f
129129
#' @param df.name Name of the input DataFrame.
130130
#' @param datasources Data sources from which to aggregate data.
131131
#' @return A DataFrame containing the variable classes from each data source.
132-
#' @import dplyr
132+
#' @importFrom dplyr %>% bind_rows row_number where all_of case_when
133133
#' @noRd
134134
.get_var_classes <- function(df.name, datasources) {
135135
cally <- call("getClassAllColsDS", df.name)
@@ -144,7 +144,6 @@ ds.standardiseDf <- function(df.name = NULL, newobj = NULL, fix_class = "ask", f
144144
#'
145145
#' @param classes A DataFrame containing variable classes across data sources.
146146
#' @return A list of variables that have class conflicts.
147-
#' @import dplyr
148147
#' @importFrom purrr map
149148
#' @noRd
150149
.identify_class_conflicts <- function(classes) {

0 commit comments

Comments
 (0)