Description Usage Arguments Details Value Examples
Select columns by type
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | select_cat(.data)
## Default S3 method:
select_cat(.data)
## S3 method for class 'data.table'
select_cat(.data)
select_cont(.data)
## Default S3 method:
select_cont(.data)
## S3 method for class 'data.table'
select_cont(.data)
|
.data |
table |
select_cat() and select_cont() return only the categorical and continuous types respectively. This is closely mirrors the dplyr function select but works with non-table values as well.
Returns a table-like object of the same class as data unless there are no columns in which case 'NULL' is returned
1 2 3 4 5 6 7 8 9 10 | data(iris)
select_cat(iris)
select_cont(iris)
## Not run:
setDT(iris)
select_cat(iris)
select_cont(iris)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.