[Chimera-users] coloring of nearly identical protein sequences in multialign viewer
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? Thanks, Sabuj Pattanayek
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?
Thanks, 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: http://www.cgl.ucsf.edu/chimera/docs/ContributedSoftware/ multalignviewer/jevtrace.html 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: http://www.cgl.ucsf.edu/chimera/docs/ContributedSoftware/ multalignviewer/multalignviewer.html#mavpref-analysis (development documentation; we don't have a release with these features yet) Best, Elaine ----- Elaine C. Meng, Ph.D. meng@cgl.ucsf.edu UCSF Computer Graphics Lab and Babbitt Lab Department of Pharmaceutical Chemistry University of California, San Francisco http://www.cgl.ucsf.edu/home/meng/index.html
Hi, 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)? Thanks, 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?
Thanks, 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:
http://www.cgl.ucsf.edu/chimera/docs/ContributedSoftware/ multalignviewer/jevtrace.html
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:
http://www.cgl.ucsf.edu/chimera/docs/ContributedSoftware/ multalignviewer/multalignviewer.html#mavpref-analysis
(development documentation; we don't have a release with these features yet) Best, Elaine ----- Elaine C. Meng, Ph.D. meng@cgl.ucsf.edu UCSF Computer Graphics Lab and Babbitt Lab Department of Pharmaceutical Chemistry University of California, San Francisco http://www.cgl.ucsf.edu/home/meng/index.html
Hi Sabuj, 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. Eric Pettersen UCSF Computer Graphics Lab pett@cgl.ucsf.edu http://www.cgl.ucsf.edu On Jul 29, 2005, at 10:58 AM, Sabuj Pattanayek wrote:
Hi,
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)?
Thanks, 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?
Thanks, 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: http://www.cgl.ucsf.edu/chimera/docs/ContributedSoftware/ multalignviewer/jevtrace.html 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: http://www.cgl.ucsf.edu/chimera/docs/ContributedSoftware/ multalignviewer/multalignviewer.html#mavpref-analysis (development documentation; we don't have a release with these features yet) Best, Elaine ----- Elaine C. Meng, Ph.D. meng@cgl.ucsf.edu UCSF Computer Graphics Lab and Babbitt Lab Department of Pharmaceutical Chemistry University of California, San Francisco http://www.cgl.ucsf.edu/home/meng/index.html
_______________________________________________ Chimera-users mailing list Chimera-users@cgl.ucsf.edu http://www.cgl.ucsf.edu/mailman/listinfo/chimera-users
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)?
Thanks, Sabuj Pattanayek
Hi Sabuj, You can use whichever you prefer. The file reader automatically figures out which format is being used. The rows/columns will be colored as specified in the alignment, and the corresponding residues in any associated structures will be colored the same way. The part of the Multalign Viewer man page about this is: http://www.cgl.ucsf.edu/chimera/docs/ContributedSoftware/ multalignviewer/multalignviewer.html#seqsel Best, Elaine
participants (3)
-
Elaine Meng
-
Eric Pettersen
-
Sabuj Pattanayek