Saturday, May 4, 2013

Coursera Data science Course

Had to choose a setup for python as the course uses python.
I chose pydev as i am already well aquainted with Eclipse.
I also downloaded and installed Python.
However when i copy pasted a sample code i got some errors for imported oauth module.

as i was totally new to python i had no idea how to install modules . I soon discovered that there are two ways of doing it.

Using the following command
python.exe C:\Downloads\oauth2-1.5.211.tar\oauth2-1.5.211\oauth2-1.5.211\setup.py install

but oauth requires setup tools
for that i had to do the following

ez_setup.py was downloaded from
http://peak.telecommunity.com/dist/ez_setup.py

python.exe C:\ez_setup.py


THe other way is to download the module and specify the path in Eclipse.
In the properties for your pydev project, there's a pane called "PyDev - PYTHONPATH", with a sub-pane called "External Libraries". You can add source folders (any folder that has an __init__.py) to the path using that pane. Your project code will then be able to import modules from those source folders.

No comments: