On Aug 6, 11:34 am, MRAB wrote:
> Iain King wrote:
> >> print >>nucleotides, seq[-76]
>
> >> last_part = line.rstrip()[-76 : ]
>
> > You all mean: seq[:-76] , right? (assuming you've already stripped
> > any junk off the end of the string)
>
> The OP said "cut out the last 76 letters
Iain King wrote:
print >>nucleotides, seq[-76]
last_part = line.rstrip()[-76 : ]
You all mean: seq[:-76] , right? (assuming you've already stripped
any junk off the end of the string)
The OP said "cut out the last 76 letters (nucleotides) from each
individual sequence and sen
On Thu, Aug 6, 2009 at 6:28 PM, Iain King wrote:
> > print >>nucleotides, seq[-76]
>
> > last_part = line.rstrip()[-76 : ]
>
> You all mean: seq[:-76] , right? (assuming you've already stripped
> any junk off the end of the string)
>
I think so, probably both of them typo'd. (What
> print >>nucleotides, seq[-76]
> last_part = line.rstrip()[-76 : ]
You all mean: seq[:-76] , right? (assuming you've already stripped
any junk off the end of the string)
Iain
--
http://mail.python.org/mailman/listinfo/python-list
PeroMHC wrote:
Hi All, So here is the problem... I have a FASTA file (used for DNA
analyses) that looks like this:
...
gnl|SRA|SRR019045.10.1 SL-XAY_956090708:2:1:0:1028.1 length=152
NCTTTATTGTATAAATGAAGTTTCACTATATCGGACGAGCGGTTCAGCAGTCATTCCGAGAC
CGATATAGTGAAACTTCATTTCTACANTACCAAACG
Dnia 06-08-2009 o 01:54:46 PeroMHC wrote:
This snippet represents 3 individual DNA sequences. Each sequences is
identified by the line starting with >
The complete file has about 10 million individual sequences.
A simple enough problem, I want to read in this data, and cut out the
last 76 lett
Dnia 06-08-2009 o 01:54:46 PeroMHC wrote:
This snippet represents 3 individual DNA sequences. Each sequences is
identified by the line starting with >
The complete file has about 10 million individual sequences.
A simple enough problem, I want to read in this data, and cut out the
last 76 lett
Hi All, So here is the problem... I have a FASTA file (used for DNA
analyses) that looks like this:
...
>gnl|SRA|SRR019045.10.1 SL-XAY_956090708:2:1:0:1028.1 length=152
NCTTTATTGTATAAATGAAGTTTCACTATATCGGACGAGCGGTTCAGCAGTCATTCCGAGAC
CGATATAGTGAAACTTCATTTCTACANTACCAAACGTCGCTCGGCAGAGCGTCG