[Biojava-l] MassCalc / Isoelectric tests

Keith James kdj@sanger.ac.uk
23 May 2002 14:55:42 +0100


>>>>> "Mike" == Jones, Mike <Mike.Jones@mpi.com> writes:

[...]

    Mike> Let us know how the tests go.

I found the MicroMass site, thanks. I wrote a simple test of MassCalc
and discovered a minor problem in the instance method:

public double getMass(SymbolList proteinSeq, boolean MH_PLUS)

which ignores the MH_PLUS argument and always falls back to the value
of MH_PLUS used in the constructor. If you use the method as
advertised it can give you the wrong answers (which is why the test is
failing - it tries all legal combinations of method calls).

Perhaps this should be changed to:

public double getMass(SymbolList proteinSeq)

If you don't mind, I'll tighten up the exception handling/throwing a
little and make a couple of public static final booleans for MH_PLUS
and MH (so that client code reads more easily).

cheers,

Keith

-- 

-= Keith James - kdj@sanger.ac.uk - http://www.sanger.ac.uk/Users/kdj =-
Pathogen Sequencing Unit, Wellcome Trust Sanger Institute, Cambridge, UK