X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fmc_view%2FPDBChain.java;fp=src%2Fmc_view%2FPDBChain.java;h=e1c90f3cc9fc58fcba20c9d6d6e552c7b479bea1;hb=304e64fb34b32659be1bbfd39fb4e15b2f79586e;hp=a3c8bee12febbe2395f5f84323f0c563d4be38e5;hpb=cfb79b69d9fa44595560659bd95d1d1cd27677ad;p=jalview.git diff --git a/src/mc_view/PDBChain.java b/src/mc_view/PDBChain.java index a3c8bee..e1c90f3 100755 --- a/src/mc_view/PDBChain.java +++ b/src/mc_view/PDBChain.java @@ -78,10 +78,27 @@ public class PDBChain public String pdbid = ""; - public PDBChain(String thePdbid, String theId) + String tfacName = "Temperature Factor"; + + + public PDBChain(String thePdbid, String theId, String tempFactorColumnName) { this.pdbid = thePdbid == null ? thePdbid : thePdbid.toLowerCase(); this.id = theId; + if (tempFactorColumnName!=null && tempFactorColumnName.length()>0) + { + tfacName = tempFactorColumnName; + } + } + + /** + * import chain data assuming Temperature Factor is in the Temperature Factor column + * @param thePdbid + * @param theId + */ + public PDBChain(String thePdbid, String theId) + { + this(thePdbid,theId, null); } /** @@ -490,15 +507,18 @@ public class PDBChain min = Math.min(min, annots[i].value); resAnnotation.setElementAt(null, i); } - AlignmentAnnotation tfactorann = new AlignmentAnnotation( - "Temperature Factor", "Temperature Factor for " + pdbid + id, + tfacName, tfacName + " for " + pdbid + id, annots, min, max, AlignmentAnnotation.LINE_GRAPH); + + tfactorann.setCalcId(getClass().getName()); + tfactorann.setSequenceRef(sequence); sequence.addAlignmentAnnotation(tfactorann); } } + /** * Colour start/end of bonds by charge *