@ Override public DescriptorValue calculate ( IAtom atom , IAtomContainer container ) { if ( factory == null ) try { factory = AtomTypeFactory . getInstance ( "org/openscience/cdk/config/data/jmol_atomtypes.txt" , container . getBuilder ( ) ) ; } catch ( Exception exception ) { return new DescriptorValue ( getSpecification ( ) , getParameterNames ( ) , getParameters ( ) , new DoubleResult ( Double . NaN ) , getDescriptorNames ( ) , exception ) ; } double covalentradius ; try { String symbol = atom . getSymbol ( ) ; IAtomType type = factory . getAtomType ( symbol ) ; covalentradius = type . getCovalentRadius ( ) ; return new DescriptorValue ( getSpecification ( ) , getParameterNames ( ) , getParameters ( ) , new DoubleResult ( covalentradius ) , getDescriptorNames ( ) ) ; } catch ( Exception exception ) { logger . debug ( exception ) ; return new DescriptorValue ( getSpecification ( ) , getParameterNames ( ) , getParameters ( ) , new DoubleResult ( Double . NaN ) , getDescriptorNames ( ) , exception ) ; } }
This method calculates the Covalent radius of an atom .