Posting a How-To for anyone who needs to run ChemScript functions using Python in KNIME.
An installation of ChemDraw includes ChemScript and its own Python installation.
KNIME Preferences should be manually pointed to this Python.
Running Python command-line uses the PYTHONPATH environment variable to know how to find ChemScript. This is created when ChemDraw is installed .
But KNIME does not know about the PYTHONPATH environment variable. So you need to append the path of the ChemDraw installation to sys.path in the KNIME Python node. Once added KNIME autocomplete will work and ChemScript functions can be used.
My Versions:
KNIME 5.4.0
KNIME Python Integration 5.4.0.v202411270736
ChemDraw 23.1.1.3 (64-bit) Proffesional
Python 3.9.10
About ChemScript:
ChemScript is the cheminformatics Software Development Kit (SDK). It contains the programming algorithms that are common throughout Revvity products. As a software developer, you can apply ChemScript to create your own scripts to
use with ChemDraw applications.
- Revvity > formerly PerkinElmer > formerly CambridgeSoft the ChemDraw developer