Created
June 9, 2019 06:59
-
-
Save karamanbk/d4476413582fbdefd8e32349dbab7732 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from datetime import datetime, timedelta,date | |
import pandas as pd | |
%matplotlib inline | |
import matplotlib.pyplot as plt | |
import numpy as np | |
from __future__ import division | |
import warnings | |
warnings.filterwarnings("ignore") | |
import plotly.plotly as py | |
import plotly.offline as pyoff | |
import plotly.graph_objs as go | |
#import Keras | |
import keras | |
from keras.layers import Dense | |
from keras.models import Sequential | |
from keras.optimizers import Adam | |
from keras.callbacks import EarlyStopping | |
from keras.utils import np_utils | |
from keras.layers import LSTM | |
from sklearn.model_selection import KFold, cross_val_score, train_test_split | |
#initiate plotly | |
pyoff.init_notebook_mode() | |
#read the data in csv | |
df_sales = pd.read_csv('sales_data.csv') | |
#convert date field from string to datetime | |
df_sales['date'] = pd.to_datetime(df_sales['date']) | |
#show first 10 rows | |
df_sales.head(10) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment