{"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.5.2"}},"nbformat":4,"nbformat_minor":0,"cells":[{"metadata":{"_cell_guid":"9fbddc0f-3d82-e2b8-1d30-ffb89d4ef258","_active":false,"collapsed":false},"source":"# This Python 3 environment comes with many helpful analytics libraries installed\n# It is defined by the kaggle/python docker image: https://github.com/kaggle/docker-python\n# For example, here's several helpful packages to load in \n\nimport numpy as np # linear algebra\nimport pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)\nimport os\nimport gc\nimport matplotlib.pyplot as plt\nimport seaborn as sns\n%matplotlib inline\n\n# Input data files are available in the \"../input/\" directory.\n# For example, running this (by clicking run or pressing Shift+Enter) will list the files in the input directory\n\nfrom subprocess import check_output\nprint(check_output([\"ls\", \"../input\"]).decode(\"utf8\"))\n\n# Any results you write to the current directory are saved as output.","execution_count":null,"cell_type":"code","outputs":[],"execution_state":"busy"},{"metadata":{"_cell_guid":"554aaedd-0596-d014-114b-5038205ca573","_active":false,"collapsed":false},"source":"df_train = pd.read_csv('../input/clicks_train.csv')\ndf_test = pd.read_csv('../input/clicks_test.csv')","execution_count":null,"cell_type":"code","outputs":[],"execution_state":"busy"},{"metadata":{"_cell_guid":"82c63f2b-a0c3-11a9-402a-23eef2ae5728","_active":false,"collapsed":false},"source":"print(df_train.head())","execution_count":null,"cell_type":"code","outputs":[],"execution_state":"busy"},{"metadata":{"_cell_guid":"0af6662a-cdc0-ff46-f3e8-7d167504d926","_active":false,"collapsed":false},"source":"print(df_trains.shapes())","execution_count":null,"cell_type":"code","outputs":[],"execution_state":"busy"},{"metadata":{"_cell_guid":"aa584292-d2dc-ec9d-a3c1-e19c92b99412","_active":false,"collapsed":false},"source":"print(df_train.groupby('display_id')['ad_id'].count().value_counts())","execution_count":null,"cell_type":"code","outputs":[],"execution_state":"busy"},{"metadata":{"_cell_guid":"d7a436b0-53a0-e602-bae7-df02536979f2","_active":false,"collapsed":false},"source":null,"execution_count":null,"cell_type":"code","outputs":[],"execution_state":"idle"}]}