Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When I upgrade data.table to the latest release (1.11.6) from 1.11.4, the following code produces a warning:
library(data.table) d1 <- data.table( S_INFO_WINDCODE = c("000001.SZ", "000001.SZ", "000001.SZ", "000001.SZ", "000001.SZ"), ANN_DT = c(19900321L, 19901231L, 19901231L, 19901231L, 19901231L), REPORT_PERIOD = c(19891231L, 19891231L, 19900331L, 19900630L, 19900930L), REPORT_YEAR = c(1989L, 1989L, 1990L, 1990L, 1990L), REPORT_QUARTER = c(4L, 4L, 1L, 2L, 3L), key = c("S_INFO_WINDCODE", "ANN_DT", "REPORT_PERIOD")) d2 <- data.table( S_INFO_WINDCODE = c("000001.SZ", "000001.SZ", "000001.SZ", "000001.SZ", "000001.SZ"), ANN_DT = c(19900321L, 19901231L, 19901231L, 19901231L, 19901231L), REPORT_PERIOD = c(19891231L, 19891231L, 19900331L, 19900630L, 19900930L), REPORT_YEAR = c(1989L, 1989L, 1990L, 1990L, 1990L), REPORT_QUARTER = c(4L, 4L, 1L, 2L, 3L), key = c("S_INFO_WINDCODE", "ANN_DT", "REPORT_PERIOD")) d3 <- merge(d1, d2, by = c("S_INFO_WINDCODE", "ANN_DT", "REPORT_PERIOD", "REPORT_YEAR", "REPORT_QUARTER"))
Warning message: In head(key(i), length(leftcols)) == names(i)[leftcols] : longer object length is not a multiple of shorter object length
My session info:
R version 3.5.1 (2018-07-02) Platform: x86_64-apple-darwin15.6.0 (64-bit) Running under: macOS High Sierra 10.13.6 Matrix products: default BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib LAPACK: /Library/Frameworks/R.framework/Versions/3.5/Resources/lib/libRlapack.dylib locale: [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8 attached base packages: [1] stats graphics grDevices utils datasets methods base other attached packages: [1] data.table_1.11.6 loaded via a namespace (and not attached): [1] compiler_3.5.1 tools_3.5.1
It is reproducible under macOS + R 3.5, Ubuntu 16.04 + R 3.5, Ubuntu 16.04 + R 3.4, Ubuntu 18.04 + R 3.5.
The text was updated successfully, but these errors were encountered:
I did some debugging and the following code will trigger the warning
d2[d1, on = c("S_INFO_WINDCODE", "ANN_DT", "REPORT_PERIOD", "REPORT_YEAR", "REPORT_QUARTER")]
The warning happens at https://github.com/Rdatatable/data.table/blob/master/R/data.table.R#L1331
Sorry, something went wrong.
Fix Rdatatable#3061
3b9455c
Closed by #3063
No branches or pull requests
When I upgrade data.table to the latest release (1.11.6) from 1.11.4, the following code produces a warning:
My session info:
It is reproducible under macOS + R 3.5, Ubuntu 16.04 + R 3.5, Ubuntu 16.04 + R 3.4, Ubuntu 18.04 + R 3.5.
The text was updated successfully, but these errors were encountered: