Difference between revisions of "Kevin Wyllie Week 3"

From LMU BioDB 2015
Jump to: navigation, search
(Syntax edits.)
(Just saving my progress in case of a connection timeout.)
Line 10: Line 10:
  
 
  cat prokaryote.txt | sed "y/atgc/tacg/" | rev
 
  cat prokaryote.txt | sed "y/atgc/tacg/" | rev
 
* Finally, the sequence of the complementary strand is (copy/pasted from the command line window):
 
 
5'- gttaaaatgccgccagcggaactggcggctgggttatacgcggaacatggtattaggcaacgtttcaagttcaatattgtcttctttggccatcgtacctattgaaatatagtaga -3'
 
  
 
===Reading Frames===  
 
===Reading Frames===  
Line 31: Line 27:
 
  cat prokaryote.txt | sed "s/.../& /g" | sed "y/t/u/"
 
  cat prokaryote.txt | sed "s/.../& /g" | sed "y/t/u/"
  
* Shown in blue: to translate this mRNA sequence:
+
* Shown in blue: to translate this mRNA sequence (yielding the +1 frame):
  
 
  cat prokaryote.txt | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
 
  cat prokaryote.txt | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
Line 42: Line 38:
  
 
  cat prokaryote.txt | '''sed "s/^..//g"''' | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
 
  cat prokaryote.txt | '''sed "s/^..//g"''' | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
 +
 +
====-1, -2, and -3 Frames====
 +
 +
* For the -1 frame, open the file as usual, and then use the pipe from "Complement of a Strand" so that the commands after it will be applied to the complementary strand (instead of the original strand). Then, add the pipe given for the +1 strand:
 +
 +
cat prokaryote.txt | sed "y/atgc/tacg/" | rev | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
 +
 +
* As before, the -2 and -3 frames can be found by making a single adjustment to the pipe for the -1 frame. For the -2 frame:
 +
 +
  cat prokaryote.txt | sed "y/atgc/tacg/" | rev | '''sed "s/^.//g"''' | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
 +
 +
* And for the -3 frame:
 +
 +
  cat prokaryote.txt | sed "y/atgc/tacg/" | rev | '''sed "s/^..//g"''' | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed

Revision as of 01:19, 20 September 2015

Complement of a Strand

Kwscreenshot1.jpg
  • Shown in green: the following command is used to open the file (using prokaryote.txt as an example).
cat prokaryote.txt
  • Shown in red: the following command is used to sequence the complementary strand (in the 5' -> 3' direction - thus the "rev" command).
cat prokaryote.txt | sed "y/atgc/tacg/" | rev

Reading Frames

The original sequence in the prokaryote.txt file will be assumed to be the top strand for this exercise.

+1, +2, and +3 Frames

Kwscreenshot2.jpg
  • Shown in green: to separate the strand into codons (resulting in the +1 frame):
cat prokaryote.txt | sed "s/.../& /g"
  • Shown in red: to convert to the mRNA sequence (treating the DNA stand as the mRNA-like strand):
cat prokaryote.txt | sed "s/.../& /g" | sed "y/t/u/"
  • Shown in blue: to translate this mRNA sequence (yielding the +1 frame):
cat prokaryote.txt | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
  • For the +2 frame, the final pipe can be slightly altered:
cat prokaryote.txt | sed "s/^.//g" | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
  • And similarly, for the +3 frame:
cat prokaryote.txt | sed "s/^..//g" | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed

-1, -2, and -3 Frames

  • For the -1 frame, open the file as usual, and then use the pipe from "Complement of a Strand" so that the commands after it will be applied to the complementary strand (instead of the original strand). Then, add the pipe given for the +1 strand:
cat prokaryote.txt | sed "y/atgc/tacg/" | rev | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
  • As before, the -2 and -3 frames can be found by making a single adjustment to the pipe for the -1 frame. For the -2 frame:
 cat prokaryote.txt | sed "y/atgc/tacg/" | rev | sed "s/^.//g" | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed
  • And for the -3 frame:
 cat prokaryote.txt | sed "y/atgc/tacg/" | rev | sed "s/^..//g" | sed "s/.../& /g" | sed "y/t/u/" | sed -f genetic-code.sed