However, the pyferret module needs to be found in order to use these pyferret methods. If the pyferret module is not found when importing, then its location needs to be added to sys.path. So something like the following, where ferdir is the (string) location of the PyFerret installation and ferdat is the (string) location of the datasets directory:
import sys
sys.path.insert(1, '%s/lib/python%d.%d/site-packages' % (ferdir, sys.version_info[0], sys.version_info[1]))
import pyferret
pyferret.addenv(FER_DIR=ferdir, FER_DAT=ferdat)
[ferret_users] Pyferret, jupyter notebook and ferretmagic
Re: [ferret_users] Pyferret, jupyter notebook and ferretmagic
- From: Karl Smith - NOAA Affiliate
Re: [ferret_users] Pyferret, jupyter notebook and ferretmagic
[Thread Prev][Thread Next][Index]