wiki:HowTo/UseOrangeFromDMG

Version 4 (modified by ales, 2 years ago) (diff)

Scripting Using Orange from the .dmg Install

It is possible to use Orange from the .dmg install on OSX for scripting without needing to install fink or build Orange from source yourself.

The easiest way is to use the python interpreter that comes bundled with it. Just run

/Applications/Orange.app/Contents/MacOS/python

from the terminal (assuming you installed Orange in /Applications directory). There is also an IPython shell script available in the same directory.

A somewhat more cumbersome way is to use Orange from the system python interpreter (/usr/bin/python) by setting the appropriate PYTHONPATH environment variable to /Applications/Orange.app/Contents/Resources

export PYTHONPATH=/Applications/Orange.app/Contents/Resources
python

To use the legacy orange and orng* module imports also add '/Applications/Orange.app/Contents/Resources/Orange/orng' to PYTHONPATH

export PYTHONPATH=/Applications/Orange.app/Contents/Resources:/Applications/Orange.app/Contents/Resources/Orange/orng
python