Python installation for trading

VJAY

Well-Known Member
#21
Have you installed talib?
Its a technical analysis library (I am not a fan of technical analysis)
You can install by typing
Python:
pip install TA-Lib
in the command prompt.

And you can follow this link in case of troubleshooting.

Once done, you can use this as follows in a jupyter notebook
Python:
import talib
talib.SMA(data)
TA-lib is insanely fast (when compared to other solutions, I believe)
And nothing is dumb :)
Once you get running, you can automate a lot of strategies from Excel or any other software
Dear UB,
Is I need to install anaconda or this ta-lib?is anaconda other software?
 

VJAY

Well-Known Member
#22
I am starting this thread for installing Python on Windows/Linux since most traders find it difficult to get running.

To begin with, I am just posting the necessary steps to get started. In case of any errors, post it along with your operating system and a screenshot of the error message so that it would be helpful in diagnosing the error.

Windows
  1. Download Anaconda. Download the correct version for your system. Download Python 3.6 version
  2. After download, right click and Run as Administrator
  3. Click Yes and proceed. Change directory to D:\anaconda3 or any other drive other than C:\
  4. Install for all users and ADD TO PATH
  5. After completing installation. Open command prompt and type conda list. This must show a list of libraries installed
  6. If this shows error, run command prompt as administrator
This is good to get going

Linux
  1. Download Anaconda. Download the correct version for your system. Download Python 3.6 version
  2. After downloading chmod +x {{download_file}} (Replace download_file with the file name)
  3. Open command prompt and ./{{download_file}}
  4. Install anywhere. /home/{{user}}/anaconda3 is preferable
  5. After completing installation. Open command prompt and type conda list. This must show a list of libraries installed
This is good to get started

Post any errors as already told.
Once installed, you can type jupyter notebook in your terminal or use anaconda navigator to open jupyter notebook
Dear UM ,
Its showing anaconda for python 3.6 ...Is it okey for version 3.7?

Untitled.png
 

UberMachine

Well-Known Member
#23
Great!!!UM....So its automated trades?...I not installed Anaconda will do it for learning....
BTW whats this bolded part


...pls explain...is it only short trades?
Bolded part is just a heading for requirements so that this could be carried out in practice
Yes. all trades are short to keep things simple (I expect the top stocks fall the next day - against the momentum)
 

UberMachine

Well-Known Member
#24
Dear UM ,
Its showing anaconda for python 3.6 ...Is it okey for version 3.7?

View attachment 27122
Yes install Python 3.6 (it works and update happen with a single command)
Anaconda and ta-lib are different. TA-LIB is required only when we are using technical indicators.
If not, then no need to install it.

Restart the system, run command prompt and type conda list. This displays the list of all libraries installed and its OK
 
Last edited:

trendtrade

niftytrader12
#25
Thanks for the response.
Looks even experienced traders are interested in learning Python.

Could I run some sort of a tutorial so that everybody could benefit out of this?
I need inputs from traders on this so that it could be better fit.
And I also intend to create a complete trading system instead of just dabbling with individual concepts
+1 from my side as well. :)

I will install all this on Sunday and will try to keep up with the stuff that you introduces here. Your idea about creating a tutorial is great. But if you do not have time, then please atleast post a few links of very selected good tutorials, blog links etc. which are targetted towards python use in stock market trading work.

Once again thanks a lot for this great initiative.
 

MSN1979

Well-Known Member
#28
I am starting this thread for installing Python on Windows/Linux since most traders find it difficult to get running.

To begin with, I am just posting the necessary steps to get started. In case of any errors, post it along with your operating system and a screenshot of the error message so that it would be helpful in diagnosing the error.

Windows
  1. Download Anaconda. Download the correct version for your system. Download Python 3.6 version
  2. After download, right click and Run as Administrator
  3. Click Yes and proceed. Change directory to D:\anaconda3 or any other drive other than C:\
  4. Install for all users and ADD TO PATH
  5. After completing installation. Open command prompt and type conda list. This must show a list of libraries installed
  6. If this shows error, run command prompt as administrator
This is good to get going

Linux
  1. Download Anaconda. Download the correct version for your system. Download Python 3.6 version
  2. After downloading chmod +x {{download_file}} (Replace download_file with the file name)
  3. Open command prompt and ./{{download_file}}
  4. Install anywhere. /home/{{user}}/anaconda3 is preferable
  5. After completing installation. Open command prompt and type conda list. This must show a list of libraries installed
This is good to get started

Post any errors as already told.
Once installed, you can type jupyter notebook in your terminal or use anaconda navigator to open jupyter notebook
In My computer I only have C:
 

MSN1979

Well-Known Member
#29
1533573705480.png


Where is my D: ? they only gave me C: I mean Dell
 

MSN1979

Well-Known Member
#30
1533575289006.png


I Installed in C: (hope thats ok UM) and I got to this point so did I install TA-LIB or not?