[Chimera-users] coloring of nearly identical protein sequences in multialign viewer
pett at cgl.ucsf.edu
Fri Jul 29 11:50:57 PDT 2005
Multalign Viewer should be able to read either SCF format. Let
me know if it doesn't.
You can hack your Chimera distribution to get the behavior you
asked for originally without too much effort. The Multalign Viewer
source is in <your installation>/share/MultAlignViewer. You will
need to change the files Consensus.py and SeqCanvas.py. In
Consensus, change the value of capitalizeAt from 0.8 to 1.1 (never
produce capital letters). In the evaluate() method, move:
if num == len(self.seqs):
self.conserved[pos] = 1
out of the surrounding 'if' (which is now never true). In SeqCanvas,
in the layout() method there is a colorConsensus() embedded
function. Remove the test for uppercase characters and reverse the
logic so that it returns 'red' for unconserved and 'black' otherwise.
I should offer better control over consensus properties,
especially now that I am working on supporting phylogenetic trees and
will be showing consensus/conservation lines for subtrees. Another
related thing I'm working on is supporting Python plugins that add
header lines that not only depict characters (in various colors) but
simple shapes such as rectangles, circles, arrows, etc.
UCSF Computer Graphics Lab
pett at cgl.ucsf.edu
On Jul 29, 2005, at 10:58 AM, Sabuj Pattanayek wrote:
> Thanks for mentioning the SCF file. I can create a script to create
> the file from the alignment. Does the SCF parser in the multialign
> viewer read the new format or the old format (I guess newer)?
> Sabuj Pattanayek
> Elaine Meng wrote:
>>> Hi all,
>>> I have a clustal aln file or a fasta file with two nearly
>>> identical aligned protein sequences. When I view them in the
>>> multialign viewer I would like to change the color of the
>>> consensus style. That is, residues which are both identical
>>> should be just black (rather than red and capitalized) and
>>> residues that are not identical should be red (or some other
>>> color that contrasts against black). Is there anyway to do this?
>>> Better yet would it be possible to not use the consensus at all
>>> and color the entire non-matching column a color of my choice?
>>> Sabuj Pattanayek
>> Hi Sabuj,
>> Currently there is no way to change the Consensus line contents
>> from the user interface. All you can do is to turn it off
>> entirely (from the Multalign Viewer window, Preferences...
>> Analysis and set the "Consensus style" to "none"). If your
>> alignment just has two sequences, however, all the columns where
>> there is no bar in the Conservation histogram when the
>> "Conservation style" is set to "identity histogram," or no
>> asterisk when the "Conservation style" is set to "Clustal
>> characters" are those in which the two sequences differ. That is
>> the closest I can get to your request, unfortunately. There is a
>> format of input that lets you color rows and columns in the
>> alignment, but then you'd have to calculate yourself which
>> positions had differing residues and then write out such a file.
>> Maybe too bothersome to be worth it. Such a file is loaded into
>> Multalign Viewer using "Tools... Load SCF/Seqsel File" and the
>> file format is described in:
>> Coming soon: we just added more and fancier options for
>> "Conservation style" which, although they do not address your
>> specific question in this mail, might interest you:
>> (development documentation; we don't have a release with these
>> features yet)
>> Elaine C. Meng, Ph.D. meng at cgl.ucsf.edu
>> UCSF Computer Graphics Lab and Babbitt Lab
>> Department of Pharmaceutical Chemistry
>> University of California, San Francisco
> Chimera-users mailing list
> Chimera-users at cgl.ucsf.edu
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Chimera-users