Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Conversion from base space to colorspace

    Hi is there a script that can do this?

    Hypothetically, I wish to convert known ESTs to colorspace so that I may assemble short reads of a transcriptome with known ESTs in a colorspace aware software.

    Thanks!
    http://kevin-gattaca.blogspot.com/

  • #2
    How about the corona_lite script:

    encodeFasta.py myRead.fasta

    output is in color space

    Ex.

    >myRead.fasta
    CGCCTTGGCCGTACAGCAGGGGCTTACGAA

    >myRead.csfasta
    C33020103031311231200032031320

    Comment


    • #3
      Why not doing the opposite, ie convert color space in sequence space usign the usual rules and after using a standard assembler? I would also ty the SAET tool which has been just posted on the SOLiD software web page on your color space reads and then convert in color space. Quick note: I have many problems in getting encodeFasta.py working correctly

      Comment


      • #4
        Originally posted by aguffanti View Post
        Why not doing the opposite, ie convert color space in sequence space usign the usual rules and after using a standard assembler? I would also ty the SAET tool which has been just posted on the SOLiD software web page on your color space reads and then convert in color space. Quick note: I have many problems in getting encodeFasta.py working correctly
        There's a thread on this topic, but in short you get the most out of color space by aligning in color space. I believe its especially important for SNPs and catching sequencing errors.

        Comment


        • #5
          color space to base space

          Indeed working in CS does have advantages in various context, from miRNA analysis to, correctly, variation detection. However, the question here was specifically on assembly I understood.

          I would definitively go, in that case, for SAET + EncodeFasta.py (used with -d option i think) + a good sequence space assembler. This is also more or less the way in which the ABI port of Velvet works.

          You may also try, if you have a good reference sequence, with the Mosaik assembler from Marth lab which handles both CS and Sequence Sapce together

          HTH, Regards,

          Alessandro

          Comment


          • #6
            A very basic script

            I couldn't find any code for doing this, so wrote a quick python script. I've validated it using a couple of test sequences in the Data Formats file from ABI, but I must warn you...use it at your own risk!

            This script requires sequence in one continuous line after the name. Interleaved sequence, split across multiple lines needs to be first merged into one single line.
            Code:
            import sys
            '''
            Combinations (FROM CMS_058717.PDF):
            AA:0, AC:1 ,AG:2 ,AT:3
            CA:1 ,CC:0 ,CG:3 ,CT:2
            GA:2 ,GC:3 ,GG:0 ,GT:1  
            TA:3 ,TC:2 ,TG:1 ,TT:0
            '''
            print "INP1: FASTA sequence file"
            
            #########
            def base2color(basepair):
                bdict={'AA':0, 'AC':1 ,'AG':2 ,'AT':3, 'CA':1 ,'CC':0 ,'CG':3 ,'CT':2, \
                       'GA':2 ,'GC':3 ,'GG':0 ,'GT':1, 'TA':3 ,'TC':2 ,'TG':1 ,'TT':0}
                return str(bdict[basepair])
            #########
            
            file1=open(sys.argv[1],'r')
            out1=open(sys.argv[1]+".color",'w')
            line1=file1.readline()
            while line1:
                if line1.startswith('#'):
                    pass
                else:
                    if line1.startswith('>'):
                        name=line1.strip()[1:]
                        line1=file1.readline()
                        seq=line1.strip()
                        clist=[]
                        for i in range(0,len(seq)-1):                                
                            b1=seq[i].upper(); b2=seq[i+1].upper(); bp='%s%s'%(b1,b2)
                            #print name,i,b1,i+1,b2,len(seq)
                            color=base2color(bp)
                            clist.append(color)
                        out1.write('>%s\n%s\n'%(name,''.join(clist)))
                line1=file1.readline()
            file1.close(); out1.close()
            print "Done!"

            Comment

            Latest Articles

            Collapse

            • seqadmin
              Strategies for Sequencing Challenging Samples
              by seqadmin


              Despite advancements in sequencing platforms and related sample preparation technologies, certain sample types continue to present significant challenges that can compromise sequencing results. Pedro Echave, Senior Manager of the Global Business Segment at Revvity, explained that the success of a sequencing experiment ultimately depends on the amount and integrity of the nucleic acid template (RNA or DNA) obtained from a sample. “The better the quality of the nucleic acid isolated...
              03-22-2024, 06:39 AM
            • seqadmin
              Techniques and Challenges in Conservation Genomics
              by seqadmin



              The field of conservation genomics centers on applying genomics technologies in support of conservation efforts and the preservation of biodiversity. This article features interviews with two researchers who showcase their innovative work and highlight the current state and future of conservation genomics.

              Avian Conservation
              Matthew DeSaix, a recent doctoral graduate from Kristen Ruegg’s lab at The University of Colorado, shared that most of his research...
              03-08-2024, 10:41 AM

            ad_right_rmr

            Collapse

            News

            Collapse

            Topics Statistics Last Post
            Started by seqadmin, 03-27-2024, 06:37 PM
            0 responses
            12 views
            0 likes
            Last Post seqadmin  
            Started by seqadmin, 03-27-2024, 06:07 PM
            0 responses
            11 views
            0 likes
            Last Post seqadmin  
            Started by seqadmin, 03-22-2024, 10:03 AM
            0 responses
            53 views
            0 likes
            Last Post seqadmin  
            Started by seqadmin, 03-21-2024, 07:32 AM
            0 responses
            69 views
            0 likes
            Last Post seqadmin  
            Working...
            X