Skip to content

Instantly share code, notes, and snippets.

@DanielaLaura
Last active June 17, 2019 19:33
Show Gist options
  • Save DanielaLaura/db1f80b4c22c3278975d5f6c130c5e4e to your computer and use it in GitHub Desktop.
Save DanielaLaura/db1f80b4c22c3278975d5f6c130c5e4e to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
{
"cells": [
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 1,
"metadata": {},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"C:\\Users\\Daniela\\Anaconda3.5\\lib\\site-packages\\sklearn\\ensemble\\weight_boosting.py:29: DeprecationWarning: numpy.core.umath_tests is an internal NumPy module and should not be imported. It will be removed in a future NumPy release.\n",
" from numpy.core.umath_tests import inner1d\n"
]
}
],
"source": [
"import pandas as pd\n",
"from sklearn.ensemble import RandomForestRegressor, RandomForestClassifier\n",
"from IPython.display import display\n",
"\n",
"from sklearn import metrics"
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [],
"source": [
"sub = pd.read_csv('tutorial_train_data1.csv', index_col='actor_account_id')"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>Unnamed: 0</th>\n",
" <th>dt_cnt</th>\n",
" <th>con_cnt</th>\n",
" <th>log_cnt</th>\n",
" <th>char_cnt</th>\n",
" <th>exp_amt</th>\n",
" <th>exp_mastery_amt</th>\n",
" <th>exhaust_cnt</th>\n",
" <th>exhaust_pvp_cnt</th>\n",
" <th>die_cnt</th>\n",
" <th>...</th>\n",
" <th>quest_cnt_cv</th>\n",
" <th>party_join_cnt_cv</th>\n",
" <th>party_kick_cnt_cv</th>\n",
" <th>guild_join_cnt_cv</th>\n",
" <th>guild_withdraw_cnt_cv</th>\n",
" <th>teleport_cnt_cv</th>\n",
" <th>pve_cnt_cv</th>\n",
" <th>pvp_cnt_cv</th>\n",
" <th>arena_cnt_cv</th>\n",
" <th>churn_yn</th>\n",
" </tr>\n",
" <tr>\n",
" <th>actor_account_id</th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>003B1E06</th>\n",
" <td>1</td>\n",
" <td>19</td>\n",
" <td>176</td>\n",
" <td>37423</td>\n",
" <td>4</td>\n",
" <td>77029</td>\n",
" <td>4229266</td>\n",
" <td>171</td>\n",
" <td>37</td>\n",
" <td>114</td>\n",
" <td>...</td>\n",
" <td>0.143501</td>\n",
" <td>0.315658</td>\n",
" <td>0</td>\n",
" <td>0.000000</td>\n",
" <td>0.0</td>\n",
" <td>0.710354</td>\n",
" <td>0.239317</td>\n",
" <td>1.074393</td>\n",
" <td>2.236068</td>\n",
" <td>0</td>\n",
" </tr>\n",
" <tr>\n",
" <th>003D42CD</th>\n",
" <td>2</td>\n",
" <td>26</td>\n",
" <td>102</td>\n",
" <td>33900</td>\n",
" <td>7</td>\n",
" <td>1797006</td>\n",
" <td>11180677</td>\n",
" <td>141</td>\n",
" <td>48</td>\n",
" <td>84</td>\n",
" <td>...</td>\n",
" <td>0.741191</td>\n",
" <td>1.265333</td>\n",
" <td>0</td>\n",
" <td>2.236068</td>\n",
" <td>0.0</td>\n",
" <td>0.869500</td>\n",
" <td>0.613837</td>\n",
" <td>2.081944</td>\n",
" <td>2.236068</td>\n",
" <td>0</td>\n",
" </tr>\n",
" <tr>\n",
" <th>006093EB</th>\n",
" <td>3</td>\n",
" <td>34</td>\n",
" <td>237</td>\n",
" <td>49063</td>\n",
" <td>1</td>\n",
" <td>0</td>\n",
" <td>12847058</td>\n",
" <td>177</td>\n",
" <td>30</td>\n",
" <td>109</td>\n",
" <td>...</td>\n",
" <td>0.281266</td>\n",
" <td>0.271776</td>\n",
" <td>0</td>\n",
" <td>0.000000</td>\n",
" <td>0.0</td>\n",
" <td>0.496655</td>\n",
" <td>0.358155</td>\n",
" <td>0.928341</td>\n",
" <td>0.000000</td>\n",
" <td>0</td>\n",
" </tr>\n",
" <tr>\n",
" <th>0067CFF2</th>\n",
" <td>4</td>\n",
" <td>10</td>\n",
" <td>28</td>\n",
" <td>4608</td>\n",
" <td>3</td>\n",
" <td>0</td>\n",
" <td>1801082</td>\n",
" <td>31</td>\n",
" <td>5</td>\n",
" <td>27</td>\n",
" <td>...</td>\n",
" <td>0.000000</td>\n",
" <td>0.000000</td>\n",
" <td>0</td>\n",
" <td>0.000000</td>\n",
" <td>0.0</td>\n",
" <td>0.000000</td>\n",
" <td>2.236068</td>\n",
" <td>0.000000</td>\n",
" <td>0.000000</td>\n",
" <td>1</td>\n",
" </tr>\n",
" <tr>\n",
" <th>00731F6C</th>\n",
" <td>5</td>\n",
" <td>5</td>\n",
" <td>21</td>\n",
" <td>4881</td>\n",
" <td>1</td>\n",
" <td>0</td>\n",
" <td>2862484</td>\n",
" <td>21</td>\n",
" <td>6</td>\n",
" <td>11</td>\n",
" <td>...</td>\n",
" <td>1.598611</td>\n",
" <td>1.629801</td>\n",
" <td>0</td>\n",
" <td>0.000000</td>\n",
" <td>0.0</td>\n",
" <td>1.564922</td>\n",
" <td>1.871842</td>\n",
" <td>0.000000</td>\n",
" <td>0.000000</td>\n",
" <td>0</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"<p>5 rows × 80 columns</p>\n",
"</div>"
],
"text/plain": [
" Unnamed: 0 dt_cnt con_cnt log_cnt char_cnt exp_amt \\\n",
"actor_account_id \n",
"003B1E06 1 19 176 37423 4 77029 \n",
"003D42CD 2 26 102 33900 7 1797006 \n",
"006093EB 3 34 237 49063 1 0 \n",
"0067CFF2 4 10 28 4608 3 0 \n",
"00731F6C 5 5 21 4881 1 0 \n",
"\n",
" exp_mastery_amt exhaust_cnt exhaust_pvp_cnt die_cnt \\\n",
"actor_account_id \n",
"003B1E06 4229266 171 37 114 \n",
"003D42CD 11180677 141 48 84 \n",
"006093EB 12847058 177 30 109 \n",
"0067CFF2 1801082 31 5 27 \n",
"00731F6C 2862484 21 6 11 \n",
"\n",
" ... quest_cnt_cv party_join_cnt_cv \\\n",
"actor_account_id ... \n",
"003B1E06 ... 0.143501 0.315658 \n",
"003D42CD ... 0.741191 1.265333 \n",
"006093EB ... 0.281266 0.271776 \n",
"0067CFF2 ... 0.000000 0.000000 \n",
"00731F6C ... 1.598611 1.629801 \n",
"\n",
" party_kick_cnt_cv guild_join_cnt_cv guild_withdraw_cnt_cv \\\n",
"actor_account_id \n",
"003B1E06 0 0.000000 0.0 \n",
"003D42CD 0 2.236068 0.0 \n",
"006093EB 0 0.000000 0.0 \n",
"0067CFF2 0 0.000000 0.0 \n",
"00731F6C 0 0.000000 0.0 \n",
"\n",
" teleport_cnt_cv pve_cnt_cv pvp_cnt_cv arena_cnt_cv \\\n",
"actor_account_id \n",
"003B1E06 0.710354 0.239317 1.074393 2.236068 \n",
"003D42CD 0.869500 0.613837 2.081944 2.236068 \n",
"006093EB 0.496655 0.358155 0.928341 0.000000 \n",
"0067CFF2 0.000000 2.236068 0.000000 0.000000 \n",
"00731F6C 1.564922 1.871842 0.000000 0.000000 \n",
"\n",
" churn_yn \n",
"actor_account_id \n",
"003B1E06 0 \n",
"003D42CD 0 \n",
"006093EB 0 \n",
"0067CFF2 1 \n",
"00731F6C 0 \n",
"\n",
"[5 rows x 80 columns]"
]
},
"execution_count": 3,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"sub.head()"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {},
"outputs": [],
"source": [
"customer1= pd.read_csv(\"00C172F0.csv\")"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"sub = pd.read_csv('tutorial_train_data1.csv', index_col='actor_account_id')\n",
"train = pd.DataFrame( index=sub.index)\n",
"for actor_account_id in train.index:\n",
" seg = pd.read_csv('traindata/' + actor_account_id + '.csv')\n",
" \n",
" log = seg['logid'].values\n",
" time = seg['time'].values\n",
" \n",
" train.loc[actor_account_id, 'log_cnt'] = len(log)\n",
" train.loc[actor_account_id, 'con_cnt']= seg.loc[seg['logid']== 1003, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'exp_amt'] = seg.loc[seg['logid']== 1016, 'use_value1_num'].sum()\n",
" train.loc[actor_account_id, 'exp_mastery_amt'] = seg.loc[seg['logid']== 1016, 'use_value3_num'].sum()\n",
" train.loc[actor_account_id, 'exhaust_cnt'] = seg.loc[seg['logid']== 1201, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'die_cnt'] = seg.loc[seg['logid']== 1202, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'quest_cnt'] = seg.loc[seg['logid']== 5004, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'party_join_cnt'] = seg.loc[seg['logid']== 1102, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'party_kick_cnt'] = seg.loc[seg['logid']== 1106, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'guild_join_cnt'] = seg.loc[seg['logid']== 6005, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'guild_withdraw_cnt'] = seg.loc[seg['logid']== 6009, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'teleport_cnt'] =seg.loc[seg['logid']== 1010, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'pve_cnt']= seg.loc[seg['logid']== 1208, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'pvp_cnt']= seg.loc[seg['logid']== 1209, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'ducel_end_cnt']= len(set(seg[(seg.logid ==1404) & (seg.logid ==1406)].count()))\n",
" train.loc[actor_account_id, 'spent_money']= seg.loc[seg['logid']== 1010, 'use_value2_num'].sum()\n",
" train.loc[actor_account_id, 'increased_money']= seg.loc[seg['logid']== 1017, 'use_value2_num'].sum()\n",
" train.loc[actor_account_id, 'decreased_money']= seg.loc[seg['logid']== 1018, 'use_value2_num'].sum()\n",
" train.loc[actor_account_id, 'increased_money2']= seg.loc[seg['logid']== 2006, 'use_value2_num'].sum()\n",
" train.loc[actor_account_id, 'increased_money3']= seg.loc[seg['logid']== 2016, 'use_value2_num'].sum()\n",
" train.loc[actor_account_id, 'decreased_money2']= seg.loc[seg['logid']== 2105, 'use_value2_num'].sum()\n",
" #train.loc[actor_account_id, 'total_increase_money']= train['increased_money']+ train['increased_money2']+ train['increased_money3']\n",
" #train.loc[actor_account_id, 'total_decrease_money']= train['decreased_money']+train['decreased_money2']\n",
" train.loc[actor_account_id, 'increased_experience']= seg.loc[seg['logid']== 1016, 'use_value1_num'].sum()\n",
" train.loc[actor_account_id, 'total_experience']= seg.loc[seg['logid']== 1016, 'new_value2_num'].sum()\n",
" train.loc[actor_account_id, 'in_item']= seg.loc[seg['logid']== 1022, 'use_value1_num'].count() \n",
" train.loc[actor_account_id, 'decreased_item']= seg.loc[seg['logid']== 1023, 'use_value1_num'].count()\n",
" train.loc[actor_account_id, 'increased_item1']= seg.loc[seg['logid']== 1022, 'new_value2_num'].sum()\n",
" train.loc[actor_account_id, 'decreased_item1']= seg.loc[seg['logid']== 1023, 'new_value2_num'].sum()\n",
" train.loc[actor_account_id, 'del_cnt']= seg.loc[seg['logid']== 1012, 'actor_account_id'].count()\n",
" train.loc[actor_account_id, 'guild_create_cnt']= seg.loc[seg['logid']== 6001, 'actor_account_id'].count() \n",
" #train[actor_account_id, 'guild_destroy_cnt']= seg.loc[seg['logid']== 6002, 'actor_account_id'].count() \n",
" train.loc[actor_account_id, 'min_time'] =time.min()\n",
" train.loc[actor_account_id, 'max_time'] = time.max()\n",
" \n",
" #train.loc[actor_account_id, 'sum'] = x.sum()\n",
" #train.loc[actor_account_id, 'range'] = x.max()-x.min()"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>log_cnt</th>\n",
" <th>con_cnt</th>\n",
" <th>exp_amt</th>\n",
" <th>exp_mastery_amt</th>\n",
" <th>exhaust_cnt</th>\n",
" <th>die_cnt</th>\n",
" <th>quest_cnt</th>\n",
" <th>party_join_cnt</th>\n",
" <th>party_kick_cnt</th>\n",
" <th>guild_join_cnt</th>\n",
" <th>...</th>\n",
" <th>increased_experience</th>\n",
" <th>total_experience</th>\n",
" <th>in_item</th>\n",
" <th>decreased_item</th>\n",
" <th>increased_item1</th>\n",
" <th>decreased_item1</th>\n",
" <th>del_cnt</th>\n",
" <th>guild_create_cnt</th>\n",
" <th>min_time</th>\n",
" <th>max_time</th>\n",
" </tr>\n",
" <tr>\n",
" <th>actor_account_id</th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" <th></th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>003B1E06</th>\n",
" <td>37423.0</td>\n",
" <td>176.0</td>\n",
" <td>77029.0</td>\n",
" <td>4229266.0</td>\n",
" <td>171.0</td>\n",
" <td>114.0</td>\n",
" <td>754.0</td>\n",
" <td>148.0</td>\n",
" <td>0.0</td>\n",
" <td>0.0</td>\n",
" <td>...</td>\n",
" <td>77029.0</td>\n",
" <td>6.408195e+09</td>\n",
" <td>4729.0</td>\n",
" <td>2516.0</td>\n",
" <td>816621.0</td>\n",
" <td>225331.0</td>\n",
" <td>3.0</td>\n",
" <td>0.0</td>\n",
" <td>2016-04-01 18:44:53.524</td>\n",
" <td>2016-05-08 10:49:15.998</td>\n",
" </tr>\n",
" <tr>\n",
" <th>003D42CD</th>\n",
" <td>33900.0</td>\n",
" <td>102.0</td>\n",
" <td>1797006.0</td>\n",
" <td>11180677.0</td>\n",
" <td>141.0</td>\n",
" <td>84.0</td>\n",
" <td>822.0</td>\n",
" <td>104.0</td>\n",
" <td>0.0</td>\n",
" <td>1.0</td>\n",
" <td>...</td>\n",
" <td>1797006.0</td>\n",
" <td>3.432078e+09</td>\n",
" <td>3390.0</td>\n",
" <td>2469.0</td>\n",
" <td>261674.0</td>\n",
" <td>329964.0</td>\n",
" <td>3.0</td>\n",
" <td>0.0</td>\n",
" <td>2016-04-04 14:13:54.266</td>\n",
" <td>2016-05-11 03:34:49.201</td>\n",
" </tr>\n",
" <tr>\n",
" <th>006093EB</th>\n",
" <td>49063.0</td>\n",
" <td>237.0</td>\n",
" <td>0.0</td>\n",
" <td>12847058.0</td>\n",
" <td>177.0</td>\n",
" <td>109.0</td>\n",
" <td>831.0</td>\n",
" <td>273.0</td>\n",
" <td>0.0</td>\n",
" <td>0.0</td>\n",
" <td>...</td>\n",
" <td>0.0</td>\n",
" <td>1.147595e+10</td>\n",
" <td>6395.0</td>\n",
" <td>3467.0</td>\n",
" <td>1053594.0</td>\n",
" <td>368977.0</td>\n",
" <td>0.0</td>\n",
" <td>0.0</td>\n",
" <td>2016-04-01 11:09:13.026</td>\n",
" <td>2016-05-10 15:35:21.701</td>\n",
" </tr>\n",
" <tr>\n",
" <th>0067CFF2</th>\n",
" <td>4608.0</td>\n",
" <td>28.0</td>\n",
" <td>0.0</td>\n",
" <td>1801082.0</td>\n",
" <td>31.0</td>\n",
" <td>27.0</td>\n",
" <td>49.0</td>\n",
" <td>12.0</td>\n",
" <td>0.0</td>\n",
" <td>0.0</td>\n",
" <td>...</td>\n",
" <td>0.0</td>\n",
" <td>6.347596e+08</td>\n",
" <td>665.0</td>\n",
" <td>474.0</td>\n",
" <td>124022.0</td>\n",
" <td>81095.0</td>\n",
" <td>0.0</td>\n",
" <td>0.0</td>\n",
" <td>2016-04-01 00:00:39.522</td>\n",
" <td>2016-05-11 01:03:42.471</td>\n",
" </tr>\n",
" <tr>\n",
" <th>00731F6C</th>\n",
" <td>4881.0</td>\n",
" <td>21.0</td>\n",
" <td>0.0</td>\n",
" <td>2862484.0</td>\n",
" <td>21.0</td>\n",
" <td>11.0</td>\n",
" <td>90.0</td>\n",
" <td>12.0</td>\n",
" <td>0.0</td>\n",
" <td>0.0</td>\n",
" <td>...</td>\n",
" <td>0.0</td>\n",
" <td>9.571554e+08</td>\n",
" <td>461.0</td>\n",
" <td>257.0</td>\n",
" <td>57062.0</td>\n",
" <td>13773.0</td>\n",
" <td>0.0</td>\n",
" <td>0.0</td>\n",
" <td>2016-04-29 16:54:39.814</td>\n",
" <td>2016-05-08 20:16:30.029</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"<p>5 rows × 31 columns</p>\n",
"</div>"
],
"text/plain": [
" log_cnt con_cnt exp_amt exp_mastery_amt exhaust_cnt \\\n",
"actor_account_id \n",
"003B1E06 37423.0 176.0 77029.0 4229266.0 171.0 \n",
"003D42CD 33900.0 102.0 1797006.0 11180677.0 141.0 \n",
"006093EB 49063.0 237.0 0.0 12847058.0 177.0 \n",
"0067CFF2 4608.0 28.0 0.0 1801082.0 31.0 \n",
"00731F6C 4881.0 21.0 0.0 2862484.0 21.0 \n",
"\n",
" die_cnt quest_cnt party_join_cnt party_kick_cnt \\\n",
"actor_account_id \n",
"003B1E06 114.0 754.0 148.0 0.0 \n",
"003D42CD 84.0 822.0 104.0 0.0 \n",
"006093EB 109.0 831.0 273.0 0.0 \n",
"0067CFF2 27.0 49.0 12.0 0.0 \n",
"00731F6C 11.0 90.0 12.0 0.0 \n",
"\n",
" guild_join_cnt ... \\\n",
"actor_account_id ... \n",
"003B1E06 0.0 ... \n",
"003D42CD 1.0 ... \n",
"006093EB 0.0 ... \n",
"0067CFF2 0.0 ... \n",
"00731F6C 0.0 ... \n",
"\n",
" increased_experience total_experience in_item \\\n",
"actor_account_id \n",
"003B1E06 77029.0 6.408195e+09 4729.0 \n",
"003D42CD 1797006.0 3.432078e+09 3390.0 \n",
"006093EB 0.0 1.147595e+10 6395.0 \n",
"0067CFF2 0.0 6.347596e+08 665.0 \n",
"00731F6C 0.0 9.571554e+08 461.0 \n",
"\n",
" decreased_item increased_item1 decreased_item1 del_cnt \\\n",
"actor_account_id \n",
"003B1E06 2516.0 816621.0 225331.0 3.0 \n",
"003D42CD 2469.0 261674.0 329964.0 3.0 \n",
"006093EB 3467.0 1053594.0 368977.0 0.0 \n",
"0067CFF2 474.0 124022.0 81095.0 0.0 \n",
"00731F6C 257.0 57062.0 13773.0 0.0 \n",
"\n",
" guild_create_cnt min_time \\\n",
"actor_account_id \n",
"003B1E06 0.0 2016-04-01 18:44:53.524 \n",
"003D42CD 0.0 2016-04-04 14:13:54.266 \n",
"006093EB 0.0 2016-04-01 11:09:13.026 \n",
"0067CFF2 0.0 2016-04-01 00:00:39.522 \n",
"00731F6C 0.0 2016-04-29 16:54:39.814 \n",
"\n",
" max_time \n",
"actor_account_id \n",
"003B1E06 2016-05-08 10:49:15.998 \n",
"003D42CD 2016-05-11 03:34:49.201 \n",
"006093EB 2016-05-10 15:35:21.701 \n",
"0067CFF2 2016-05-11 01:03:42.471 \n",
"00731F6C 2016-05-08 20:16:30.029 \n",
"\n",
"[5 rows x 31 columns]"
]
},
"execution_count": 7,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"train.head()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.5"
},
"toc": {
"base_numbering": 1,
"nav_menu": {},
"number_sections": true,
"sideBar": true,
"skip_h1_title": false,
"title_cell": "Table of Contents",
"title_sidebar": "Contents",
"toc_cell": false,
"toc_position": {},
"toc_section_display": true,
"toc_window_display": false
},
"varInspector": {
"cols": {
"lenName": 16,
"lenType": 16,
"lenVar": 40
},
"kernels_config": {
"python": {
"delete_cmd_postfix": "",
"delete_cmd_prefix": "del ",
"library": "var_list.py",
"varRefreshCmd": "print(var_dic_list())"
},
"r": {
"delete_cmd_postfix": ") ",
"delete_cmd_prefix": "rm(",
"library": "var_list.r",
"varRefreshCmd": "cat(var_dic_list()) "
}
},
"types_to_exclude": [
"module",
"function",
"builtin_function_or_method",
"instance",
"_Feature"
],
"window_display": false
}
},
"nbformat": 4,
"nbformat_minor": 2
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment