Lines Matching refs:SDcols
33 The simpler usage of `.SD` is for column subsetting (i.e., when `.SDcols` is specified); as this ve…
67 ## Column Subsetting: `.SDcols`
69 …act what `.SD` is is to limit the _columns_ contained in `.SD` using the `.SDcols` argument to `[`:
73 Pitching[ , .SD, .SDcols = c('W', 'L', 'G')]
80 … `character`/`factor`/`numeric` types are common. We can use `.SD` and `.SDcols` to batch-convert …
90 Teams[ , sapply(.SD, is.character), .SDcols = fkt]
106 Teams[ , (fkt) := lapply(.SD, factor), .SDcols = fkt]
113 …SDcols` argument is quite flexible; above, we supplied a `character` vector of column names. In ot…
118 # while .SDcols accepts a logical vector,
122 Teams[ , (fkt_idx) := lapply(.SD, as.character), .SDcols = fkt_idx]
126 Lastly, we can do pattern-based matching of columns in `.SDcols` to select all columns which contai…
129 Teams[ , .SD, .SDcols = patterns('team')]
135 Teams[ , (team_idx) := lapply(.SD, factor), .SDcols = team_idx]
168 Pitching[ , coef(lm(ERA ~ ., data = .SD))['W'], .SDcols = c('W', rhs)]
232 …f course be combined with `.SDcols` to return only portions of the `data.table` for each `.SD` (wi…