Just check the strand. If its StrandedFeature.NEGATIVE then its complement, otherwise it isn't.
examples: feature.getStrand() --> StrandedFeature.NEGATIVE = complement feature.getStrand().getValue() --> -1 = complement feature.getStrand().getToken() --> - = complement
Simon
-- Bioinformatics Specialist Institute for Biological Sciences National Research Council of Canada [T] 613-990-0561 [F] 613-952-9092 [EMAIL PROTECTED]
Y D Sun wrote:
-----Original Message-----
From: Thomas Down [mailto:[EMAIL PROTECTED] Sent: 08 July 2003 13:49
To: Y D Sun
Cc: [EMAIL PROTECTED]
Subject: Re: [Biojava-l] Complement feature in CDS table
Once upon a time, Y D Sun wrote:
Dear all,features in a
How to filter the complement feature in CDS? I get the
CDS table using the following code:The complement(xxx..yyy) stuff is the feature's location, rather than part of the qualifier-value data. In BioJava, this will be represented by a feature having a location from xxx to yyy, and being on the negative strand.
Map m = f.getAnnotation().asMap(); // f is a
Feature containing a CDS table
String ge = m.get("gene").toString(); // ok
String pr = m.get("product").toString(); // ok
...
String co = m.get("complement").toString(); // return nothing although the CDS table includes complement(int..int).
I want to check if a CDS contains the keyword "complement". Is there any method to do so?
George
For more information, see:
http://www.ebi.ac.uk/embl/Documentation/FT_definitions/feature_table.htm l
Thomas.
_______________________________________________
Biojava-l mailing list - [EMAIL PROTECTED]
http://biojava.org/mailman/listinfo/biojava-l
_______________________________________________ Biojava-l mailing list - [EMAIL PROTECTED] http://biojava.org/mailman/listinfo/biojava-l