我正在尝试编写一个 python 脚本来检索我输入的化合物的沸点、熔点、分子量、化学结构和密度。
我正在查看数据库并找到chemspipy和PubChemPy,但它们都无法检索我需要的所有属性。
我有一部分使用 chemspipy 编写的脚本,效果很好:
from chemspipy import ChemSpider
import urllib
cs = ChemSpider('my_token')
def getImage(compound):
c = cs.search(compound)[0]
imgUrl = c.image_url
urllib.request.urlretrieve(imgUrl, c.common_name + '.png')
def getWeight(compound):
c = cs.search(compound)[0]
return(c.molecular_weight)
但我仍然需要找到一种方法来检索沸点/熔点。
(这是我在这里的第一个问题,如果发错地方请见谅!)