The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.
The goal of factor256 is to minimize the memory footprint of data analysis that uses categorical variables with fewer than 256 unique values.
You can install the development version of factor256 from GitHub with:
This is a basic example which shows you how to solve a common problem:
library(factor256)
x <- factor256(LETTERS)
typeof(x)
#> [1] "raw"
identical(recompose256(x), LETTERS)
#> [1] TRUE
library(data.table)
DT <-
CJ(Year = 2000:2020,
State = rep_len(c("WA", "SA", "NSW", "NT", "TAS", "VIC", "QLD"), 1000),
Age = rep_len(0:100, 10000))
# pryr::object_size(DT)
# 3.36GB
for (j in seq_along(DT)) {
set(DT, j = j, value = factor256(.subset2(DT, j)))
}
# pryr::object_size(DT)
# 630 MB
These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.