[Biojava-l] two questions from new biojava user

Schreiber, Mark mark.schreiber@agresearch.co.nz
Wed, 2 Oct 2002 10:10:35 +1200


Hi -

I'm not sure I fully understand the problem you describe in 1) using the
following code:

import org.biojava.bio.*;
import org.biojava.bio.seq.*;
import org.biojava.bio.seq.io.*;
import org.biojava.bio.symbol.*;

public class Transcribe {

  public static void main(String[] args) throws Exception{

    SymbolList dna = DNATools.createDNA("agactcgggctctttcctacg");
    SymbolList rna = RNATools.transcribe(dna);
    SymbolList protein = RNATools.translate(rna);

    //print DNA
    System.out.println("dna:\t"+dna.seqString());
    System.out.println("rna:\t"+rna.seqString());
    System.out.println("protein:\t"+protein.seqString());
  }
}

I get:

dna:	agactcgggctctttcctacg 
rna:	agacucgggcucuuuccuacg
protein:	RLGLFPT

Which is what I expect. Note that the transcribed and translated
SymbolLists are views onto the original which may be confusing but you
really don't need to worry about it 99% of the time.

As to point 2). The version you have is a dated snap shot of the CVS
tree made on 23 August 2002 so its fairly up to date. It contains things
that are not compatible with BioJava 1.2 whereas BioJava 1.2.2 is
everything from the CVS tree that doesn't break BioJava 1.2

The only more up to date version is biojava-live which can be obtained
via CVS. If the above program doesn't work with your snapshot I
recommend getting the CVS version.

Hope this helps,

Mark


> -----Original Message-----
> From: Dave Barkan [mailto:dbarkan@snowball.pcbi.upenn.edu] 
> Sent: Wednesday, 2 October 2002 5:40 a.m.
> To: biojava-l@biojava.org
> Subject: [Biojava-l] two questions from new biojava user
> 
> 
> Hey all, new to Biojava and have two quick questions.
> 
> 1)  I am attempting to use the transcribe() method of the 
> RNATools class and am having trouble; the program stops and 
> outputs "org.biojava.bio.symbol.TranslatedSymbolList" before 
> it returns from the
> method.   I examined the source code of the transcribe() method and
> followed its call tree and don't actually see where the 
> "transcription" is taking place; the TranslatedSymbolList 
> constructor just sets the object to have the original (DNA) 
> symbol list as its "source" instance variable.  I was just 
> wondering if I am not understanding everything or if the 
> method hasn't been fully implemented.
> 
> 2) (this might help answer 1).  I am working with the biojava 
> source with the ant-build. I downloaded the version 
> "biojava-20020823.tar.gz" and set the classpath to the source 
> folder (also to the xerces and bytecode jar files).  I just 
> wanted to make sure this is the correct version; it is a bit 
> suspicious as the tar file doesn't have a version tag, but it 
> seems to have a lot of methods that 'biojava-1.22.tar.gz" 
> doesn't.  If I am missing something obvious, my apologies as 
> I am still new to some of the "administrative" aspects of java.
> 
> Thanks, enjoying it so far!  Please cc me with any info you 
> might have so I don't wait until tomorrow to get the digest.
> 
> dave
> 
> 
> 
> _______________________________________________
> Biojava-l mailing list  -  Biojava-l@biojava.org 
> http://biojava.org/mailman/listinfo/biojava-l
> 
=======================================================================
Attention: The information contained in this message and/or attachments
from AgResearch Limited is intended only for the persons or entities
to which it is addressed and may contain confidential and/or privileged
material. Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by persons or
entities other than the intended recipients is prohibited by AgResearch
Limited. If you have received this message in error, please notify the
sender immediately.
=======================================================================