Adrian, Thanks for the quick reply.
I am running OS X 10.10.2 and have a Parallels 10.1.4 Windows 7 virtual machine. I can run Spyder 2.3.2 in both OS X and Windows 7. Both the Windows and OS X Spyder were installed from downloaded installers. I can execute Python code on both instances. NetworkX was installed via the OS X command line using pip and I have tried to access it in both the OS X and Windows Spyder, but get the same message. I opened a python interpreter via the command line command. The attached screenshot shows the result; which I interpret to show that networkx was imported. I hope this helps in understanding my problem. Chris > On 19 Mar 2015, at 1:01 am, Adrian Klaver <adrian.kla...@aklaver.com> wrote: > > On 03/18/2015 02:27 AM, Chris wrote: >> Hi, >> >> I am trying to run NetworkX in Spyder but am unable to get the module >> networkx recognised. >> >> I downloaded NetworkX from http://pypi.python.org/pypi/networkx and >> installed NetworkX via pip using "pip install networkx". It appeared to >> complete OK. When I repeat the command I get >> >> Last login: Wed Mar 18 20:07:35 on ttys000 >> >> Fl1cker:~ cbhe$ pip install networkx >> >> Requirement already satisfied (use --upgrade to upgrade): networkx in >> /Library/Python/2.7/site-packages/networkx-1.9.1-py2.7.egg >> >> Requirement already satisfied (use --upgrade to upgrade): >> decorator>=3.4.0 in >> /Library/Python/2.7/site-packages/decorator-3.4.0-py2.7.egg (from networkx) >> >> Fl1cker:~ cbhe$ >> >> >> which suggests to me that it is installed. >> >> However when I try to import network in Spyder using "import networkx as >> nx" I get >> >> runfile('Z:/Users/cbhe/scripts/netw0.py', wdir='Z:/Users/cbhe/scripts') >> Traceback (most recent call last): >> >> File "<ipython-input-2-5455c9a69031>", line 1, in <module> >> runfile('Z:/Users/cbhe/scripts/netw0.py', wdir='Z:/Users/cbhe/scripts') >> >> File >> "C:\Python27\lib\site-packages\spyderlib\widgets\externalshell\sitecustomize.py", >> line 601, in runfile >> execfile(filename, namespace) >> >> File >> "C:\Python27\lib\site-packages\spyderlib\widgets\externalshell\sitecustomize.py", >> line 66, in execfile >> exec(compile(scripttext, filename, 'exec'), glob, loc) >> >> File "Z:/Users/cbhe/scripts/netw0.py", line 1, in <module> >> import networkx as nx >> >> ImportError: No module named >> http://www.postgresql.org/docs/9.3/interactive/app-pgbasebackup.html >> >> I can only think that it is a Python Path issue, but I have tried >> numerous paths that all produce the same result. >> >> Any suggestions would be really welcome as I am being held up by this >> problem. > > Some information is needed I think. > > 1) Your pip install lines look they where done on a Unix* machine, but the > traceback looks like it comes from a Windows machine. > Could you explain your layout some? > > 2) What version of Spyder and how was it installed? > > 3) Can you open a Python interpreter and import networkx? > > -- > Adrian Klaver > adrian.kla...@aklaver.com > > -- > You received this message because you are subscribed to a topic in the Google > Groups "spyder" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/spyderlib/RxXRhb2pQOI/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > spyderlib+unsubscr...@googlegroups.com. > To post to this group, send email to spyderlib@googlegroups.com. > Visit this group at http://groups.google.com/group/spyderlib. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout> -- You received this message because you are subscribed to the Google Groups "spyder" group. To unsubscribe from this group and stop receiving emails from it, send an email to spyderlib+unsubscr...@googlegroups.com. To post to this group, send email to spyderlib@googlegroups.com. Visit this group at http://groups.google.com/group/spyderlib. For more options, visit https://groups.google.com/d/optout.