pubchem
Version:
pubchem simplifies the data retrieval from the PubChem API.
13 lines • 483 B
JavaScript
import jp from 'jsonpath';
/**
* Returns the computed data section of a compound
*
* @param data Data of a compound data request to the PubChem API
* @returns Computed Data section
*/
export function getComputedDataSection(data) {
const computedData = jp.query(data, '$.Section[?(@.TOCHeading==="Chemical and Physical Properties")]' +
'.Section[?(@.TOCHeading==="Computed Properties")]');
return computedData;
}
//# sourceMappingURL=getComputedDataSection.js.map