How to overcome R memory error
0
0
Entering edit mode
4.5 years ago
2405592M ▴ 150

My R script keeps returning the following error:

Error in readLines(file) : R character strings are limited to 2^31-1 bytes

Clearly, my input fasta files are too big. What is the best way around this problem. I initially thought I'd have to convert this segment of the script into python, but I was hoping to find an R-based solution first.

RNA-Seq FASTA R • 2.2k views
ADD COMMENT
1
Entering edit mode

Can you explain what you are trying to do. Code alone without any comments is not appropriate as a question.

ADD REPLY
0
Entering edit mode

The script calculates the relative synonymous codon usage of transcript coding sequences (these are the input fasta files). The first step converts the input fasta file into character strings (which is required for the uco function) and I think that is the origin of the error.

ADD REPLY
0
Entering edit mode

Are you sure you are reading in a transcripts fasta? I can't think of a gene coding region being this long.

ADD REPLY

Login before adding your answer.

Traffic: 2197 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6