From f90be04043fa02c4089e57ae5f27e66f4a2a1f9c Mon Sep 17 00:00:00 2001 From: John Pope Date: Sun, 1 Oct 2017 19:56:00 -0400 Subject: [PATCH 1/3] tensorflow + python 2 / pandas environment. --- README.md | 9 +++++++++ main.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index b863b5f..b22c03b 100644 --- a/README.md +++ b/README.md @@ -11,3 +11,12 @@ Such as: ``` python main.py --stock_symbol=SP500 --train --input_size=5 --lstm_size=128 --max_epoch=50 ``` + + +Install Conda https://conda.io/docs/installation.html +Cheatsheet https://conda.io/docs/_downloads/conda-cheatsheet.pdf + +## Python 2.7 +conda create -n tensorflow-p2 python=2.7 +source activate tensorflow-p2 +conda install numpy pandas matplotlib tensorflow jupyter notebook scipy scikit-learn nb_conda nltk diff --git a/main.py b/main.py index 8d91447..4676051 100644 --- a/main.py +++ b/main.py @@ -57,7 +57,7 @@ def load_sp500(input_size, num_steps, k=None, target_symbol=None, test_ratio=0.0 print info['file_exists'].value_counts().to_dict() info = info[info['file_exists'] == True].reset_index(drop=True) - info = info.sort('market_cap', ascending=False).reset_index(drop=True) + info = info.sort_values('market_cap', ascending=False).reset_index(drop=True) if k is not None: info = info.head(k) From 4512ba340189361bd64ecc97b1b0825deaca4176 Mon Sep 17 00:00:00 2001 From: John Pope Date: Mon, 2 Oct 2017 13:57:25 -0400 Subject: [PATCH 2/3] spaces --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index b22c03b..3c07cc8 100644 --- a/README.md +++ b/README.md @@ -13,10 +13,10 @@ python main.py --stock_symbol=SP500 --train --input_size=5 --lstm_size=128 --max ``` -Install Conda https://conda.io/docs/installation.html -Cheatsheet https://conda.io/docs/_downloads/conda-cheatsheet.pdf - -## Python 2.7 -conda create -n tensorflow-p2 python=2.7 -source activate tensorflow-p2 -conda install numpy pandas matplotlib tensorflow jupyter notebook scipy scikit-learn nb_conda nltk +Install Conda https://conda.io/docs/installation.html . +Cheatsheet https://conda.io/docs/_downloads/conda-cheatsheet.pdf . + . +## Python 2.7 . +conda create -n tensorflow-p2 python=2.7 . +source activate tensorflow-p2 . +conda install numpy pandas matplotlib tensorflow jupyter notebook scipy scikit-learn nb_conda nltk . From e130c8157878ecefea09752e98b54cb1608e43fe Mon Sep 17 00:00:00 2001 From: John Pope Date: Mon, 2 Oct 2017 13:58:02 -0400 Subject: [PATCH 3/3] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3c07cc8..f0b9fab 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ python main.py --stock_symbol=SP500 --train --input_size=5 --lstm_size=128 --max Install Conda https://conda.io/docs/installation.html . Cheatsheet https://conda.io/docs/_downloads/conda-cheatsheet.pdf . . -## Python 2.7 . -conda create -n tensorflow-p2 python=2.7 . -source activate tensorflow-p2 . -conda install numpy pandas matplotlib tensorflow jupyter notebook scipy scikit-learn nb_conda nltk . +## Python 2.7 +conda create -n tensorflow-p2 python=2.7 +source activate tensorflow-p2 +conda install numpy pandas matplotlib tensorflow jupyter notebook scipy scikit-learn nb_conda nltk