From 3161be70bb06b580f12f9cef4b9e71cd6f71a38f Mon Sep 17 00:00:00 2001 From: tcofoegbu Date: Mon, 25 Jan 2016 15:06:26 +0000 Subject: [PATCH] JAL-1998 bugfix for division by zero error for PDB entries with chain(s) consisiting of a single residue --- src/MCview/PDBChain.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MCview/PDBChain.java b/src/MCview/PDBChain.java index 6d5f9fe..a43626f 100755 --- a/src/MCview/PDBChain.java +++ b/src/MCview/PDBChain.java @@ -252,7 +252,7 @@ public class PDBChain * If > 99% 'P', flag as nucleotide; note the count doesn't include the last * residue */ - if (residues.size() > 0 && (numNa / (residues.size() - 1) > 0.99)) + if (residues.size() > 1 && (numNa / (residues.size() - 1) > 0.99)) { isNa = true; } -- 1.7.10.2