Custom annotation

Issue #361 resolved
leleonp created an issue

I have a set of 50 pdb structures. I did create pdbs with the pdbaln function. I have also a custom annotation of my structures. How can combine the pdbs and the annotation? (similar to transducin data) In order to plot hclustplot and other function using color of custom annotations. Thanks in advance

Luis

Comments (4)

  1. Barry Grant

    Any vector that matches the order of structures in your pdbs object should work.

    For example:

    > myanot <- c("red", "red", "blue", "black")
    > mypdbs <- c("1bg2", "1i6i", "1i5s", "2ncd")
    > pdbs <- pdbaln(mypdbs)
    
    # Make an ugly plot
    > matplot(t(pdbs$b), typ="l", col=myanot, lty=1, lwd=2)
    

    You can also use a named vector with the names matching your pdbs$id for example then you don't have to worry about the order and just remember to use the names to access your annotation vector.

  2. Log in to comment