Package org.openscience.cdk.formula
Class MassToFormulaTool
- java.lang.Object
-
- org.openscience.cdk.formula.MassToFormulaTool
-
@Deprecated public class MassToFormulaTool extends Object
Deprecated.Please use MolecularFormulaGeneratorTool to determine molecular formula consistent with a given accurate mass. The molecular formulas are not validate. It only consist in generate combination according object (see MolecularFormulaChecker). The algorithm is published in Rojas-Cherto M. et.al. [Rojas-Cherto, Miguel et. al.. Bioinformatics. 2011. ].
MassToFormulaTool mf = new MassToFormulaTool(); double myMass = 133.004242; IMolecularFormulaSet mfSet = mf.generate(myMass);
The elements are listed according on difference with the proposed mass.
- Author:
- miguelrojasch
- Source code:
- main
- Belongs to CDK module:
- formula
- Created on:
- 2007-03-01
-
-
Constructor Summary
Constructors Constructor Description MassToFormulaTool(IChemObjectBuilder builder)
Deprecated.Construct an instance of MassToFormulaTool.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description IMolecularFormulaSet
generate(double mass)
Deprecated.Method that actually does the work of extracting the molecular formula.List<IRule>
getRestrictions()
Deprecated.Get the restrictions that must be presents in the molecular formula.void
setDefaultRestrictions()
Deprecated.Set the default restrictions that must be presents in the molecular formula.void
setRestrictions(List<IRule> rulesNew)
Deprecated.Set the restrictions that must be presents in the molecular formula.
-
-
-
Constructor Detail
-
MassToFormulaTool
public MassToFormulaTool(IChemObjectBuilder builder)
Deprecated.Construct an instance of MassToFormulaTool. It is necessary because different matrix have to build. Furthermore the default restrictions are initiated.- See Also:
setDefaultRestrictions()
-
-
Method Detail
-
setRestrictions
public void setRestrictions(List<IRule> rulesNew) throws CDKException
Deprecated.Set the restrictions that must be presents in the molecular formula.- Parameters:
rulesNew
- The restrictions to impose- Throws:
CDKException
- See Also:
getRestrictions()
,setDefaultRestrictions()
,IRule
-
getRestrictions
public List<IRule> getRestrictions()
Deprecated.Get the restrictions that must be presents in the molecular formula.- Returns:
- The restrictions to be imposed
- See Also:
setDefaultRestrictions()
-
setDefaultRestrictions
public void setDefaultRestrictions()
Deprecated.Set the default restrictions that must be presents in the molecular formula.- See Also:
getRestrictions()
-
generate
public IMolecularFormulaSet generate(double mass)
Deprecated.Method that actually does the work of extracting the molecular formula.- Parameters:
mass
- molecular formula to create from the mass- Returns:
- the filled molecular formulas as IMolecularFormulaSet
-
-