''Calloc' could not allocate memory When trying to Knit an RMD file into an HTML
I am trying to knit an RMD file into an HTML report using a pretty large dataset (2,600,000 rows with 18 columns) and I keep getting a memory error on the same line of code... Here is the full error:
Quitting from lines 148-149 (banking_complaint_R_report.Rmd) Error in gsub("[\n]{2,}$", "\n", x) : 'Calloc' could not allocate memory (18446744071562067968 of 1 bytes) Calls: ... lapply -> FUN -> sew.character -> comment_out -> gsub Execution halted
This is my code on line 148-149:
sqldf("SELECT columnX, COUNT(*) AS total FROM my_data GROUP BY columnX ORDER BY total DESC")
I already tried searching this error and found a solution to increase my memory allocation with the memory.limit(size=100000) that I typed directly into the R studio console. but I still am getting the same above error when I try to Knit into an HTML file. I also tried restarting my computer without opening any other applications and still getting the error...
I should also note that when I run all the code chunks individually it works so just the Knit into an HTML seems to be the problem.
How can I solve this problem?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
