You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
uniqueN is equivalent to length(unique(x)) but much faster. It accepts atomic vectors, data.frames and data.tables. The number of unique rows are computed directly without materialising the intermediate unique data.table and is therefore memory efficient as well.
uniqueN is not equivalent to length(unique(x)) when x is a data.frame or data.table. Perhaps it should read something like:
uniqueN is equivalent to length(unique(x)) when x is a vector, and nrow(unique(x)) when x is a data.frame or data.table. The number of unique rows are computed directly without materialising the intermediate unique data.table and is therefore faster and more memory efficient.
The text was updated successfully, but these errors were encountered:
from
?uniqueN
uniqueN
is equivalent tolength(unique(x))
but much faster. It accepts atomicvectors
,data.frames
anddata.tables
. The number of unique rows are computed directly without materialising the intermediate unique data.table and is therefore memory efficient as well.uniqueN
is not equivalent tolength(unique(x))
when x is adata.frame
ordata.table
. Perhaps it should read something like:uniqueN
is equivalent tolength(unique(x))
when x is avector
, andnrow(unique(x))
when x is adata.frame
ordata.table
. The number of unique rows are computed directly without materialising the intermediate unique data.table and is therefore faster and more memory efficient.The text was updated successfully, but these errors were encountered: