{"metadata":{"kernelspec":{"language":"python","display_name":"Python 3","name":"python3"},"language_info":{"pygments_lexer":"ipython3","nbconvert_exporter":"python","version":"3.6.4","file_extension":".py","codemirror_mode":{"name":"ipython","version":3},"name":"python","mimetype":"text/x-python"}},"nbformat_minor":4,"nbformat":4,"cells":[{"cell_type":"code","source":"import numpy as np # linear algebra\nimport pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)\nimport matplotlib.pyplot as plt\n\ntrain  = pd.read_csv('../input/tabular-playground-series-aug-2022/train.csv')","metadata":{"_uuid":"8f2839f25d086af736a60e9eeb907d3b93b6e0e5","_cell_guid":"b1076dfc-b9ad-4769-8c92-a6c4dae69d19","execution":{"iopub.status.busy":"2022-08-13T00:46:39.930480Z","iopub.execute_input":"2022-08-13T00:46:39.931917Z","iopub.status.idle":"2022-08-13T00:46:40.176754Z","shell.execute_reply.started":"2022-08-13T00:46:39.931762Z","shell.execute_reply":"2022-08-13T00:46:40.175296Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# make list of measurement columns\nm_cols = [f'measurement_{num}' for num in range(18)]","metadata":{"execution":{"iopub.status.busy":"2022-08-13T00:46:40.179573Z","iopub.execute_input":"2022-08-13T00:46:40.180015Z","iopub.status.idle":"2022-08-13T00:46:40.187743Z","shell.execute_reply.started":"2022-08-13T00:46:40.179967Z","shell.execute_reply":"2022-08-13T00:46:40.185870Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# define plotting helper method\n\ndef plot_m_cols(kind):\n    '''If there is an easier way, I assume there is, please let me know.'''\n    \n    fig, ax = plt.subplots(3, 6, figsize=(15, 15))\n    \n    idx = 0\n    for row in range(3):\n        for col in range(6):\n            train[m_cols[idx]].plot(kind=kind, ax=ax[row][col])\n            idx += 1","metadata":{"execution":{"iopub.status.busy":"2022-08-13T00:46:40.190413Z","iopub.execute_input":"2022-08-13T00:46:40.191913Z","iopub.status.idle":"2022-08-13T00:46:40.201445Z","shell.execute_reply.started":"2022-08-13T00:46:40.191845Z","shell.execute_reply":"2022-08-13T00:46:40.199705Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# histograms\nplot_m_cols('hist')","metadata":{"execution":{"iopub.status.busy":"2022-08-13T00:46:40.205249Z","iopub.execute_input":"2022-08-13T00:46:40.206186Z","iopub.status.idle":"2022-08-13T00:46:43.076783Z","shell.execute_reply.started":"2022-08-13T00:46:40.206103Z","shell.execute_reply":"2022-08-13T00:46:43.075318Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# box\nplot_m_cols('box')","metadata":{"execution":{"iopub.status.busy":"2022-08-13T00:46:43.078903Z","iopub.execute_input":"2022-08-13T00:46:43.079443Z","iopub.status.idle":"2022-08-13T00:46:45.470579Z","shell.execute_reply.started":"2022-08-13T00:46:43.079394Z","shell.execute_reply":"2022-08-13T00:46:45.469313Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# density\nplot_m_cols('kde')","metadata":{"execution":{"iopub.status.busy":"2022-08-13T00:46:45.472313Z","iopub.execute_input":"2022-08-13T00:46:45.472683Z","iopub.status.idle":"2022-08-13T00:46:57.889987Z","shell.execute_reply.started":"2022-08-13T00:46:45.472642Z","shell.execute_reply":"2022-08-13T00:46:57.888865Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# area\nplot_m_cols('area')","metadata":{"execution":{"iopub.status.busy":"2022-08-13T00:46:57.892198Z","iopub.execute_input":"2022-08-13T00:46:57.892734Z","iopub.status.idle":"2022-08-13T00:47:04.741858Z","shell.execute_reply.started":"2022-08-13T00:46:57.892684Z","shell.execute_reply":"2022-08-13T00:47:04.740624Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"Measurements 0, 1, 2 and 13 all show some positive skewness. Measurement 11 is slightly negatively skewed.","metadata":{}},{"cell_type":"code","source":"for col in m_cols:\n    print(f'{col}: {train[col].skew()}')","metadata":{"execution":{"iopub.status.busy":"2022-08-13T00:51:23.385557Z","iopub.execute_input":"2022-08-13T00:51:23.386068Z","iopub.status.idle":"2022-08-13T00:51:23.404655Z","shell.execute_reply.started":"2022-08-13T00:51:23.386030Z","shell.execute_reply":"2022-08-13T00:51:23.402899Z"},"trusted":true},"execution_count":null,"outputs":[]}]}