r is running out of memory
When i am trying loading gene expression counts downloaded from tcga (I have 859 samples with raw counts of 60000 rows).
I GET THIS ERROR and R STOPPED FOR NO REASON!
I check the memory to find out that my memory is nearly full.BUT i have 16GB RAM.
counts_df <- counts_files %>%
lapply(function(x) {
tmp <- read_tsv(x, col_names = F) %>%
purrr::set_names("gene_id", basename(x))
cat(which(counts_files == x), "of", length(counts_files), "n")
return(tmp)
}) %>%
reduce(function(x, y) full_join(x, y, by = "gene_id")) %>%
dplyr::select(gene_id, metadata$file_name) %>%
set_names("gene_id", metadata$TCGA_id_full) %>%
dplyr::slice(1:(nrow(.)-5))
• 33 views
Read more here: Source link