In Response To 'Re: How to color protein residues with an array?'
Thank you very much for your response.
Here is an example of a simple protein (inspired by the Mathematica help file on the pdb-format):
(one can also find it via: Import["ExampleData/1PPT.pdb"] ).
And the list I want to use to color the residues is very similar to:
ColorArray = RandomReal[1, 36]
, ie. a list of numbers between 0 and 1 of the same length as number of residues in the protein. I hoped these values could for instance be used in ColorFunction (on of the options in the Import function) via Hue[ColorArray] or RGBColor[0, 0, ColorArray], thereby giving a stronger coloring for a higher value of the element of te list.
Because the form (also from the Mathematica manual):
Import["ExampleData/1PPT.pdb", ColorFunction -> "Residue"]
also requires a loop through the different residues in which they are colored (at a lower level) , I would think/hope that this is also possible for an arbitrary color function or list.
Thank you very much in advance for any help!
With kind regards,
ps. In the case the hetero atom in this pdb-file, that is listed as the 37th residue, would be a problem: I have attached the same pdb-file where the line of the zinc atom is deleted.
Attachment: 1PPT_NoZincHeteroAtom.pdb, URL: http://www.rcsb.org/pdb/download/downloadFile.do?fileFormat=\pdb&compression=NO&structureId=1PPT,