{"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":"markdown","source":"# ASHRAE ENERGY PREDICTION III","metadata":{"id":"PRDnm0lhzEyp"}},{"cell_type":"markdown","source":"**Made By:**\n**Reem Tarek, Asmaa Elsayed, Hanya Mostafa**","metadata":{}},{"cell_type":"markdown","source":"# 1.Business Problem :\n","metadata":{"id":"MqmFZCwjzuD1"}},{"cell_type":"markdown","source":"## 1.1 Description :","metadata":{"id":"3WSJIqQuzuGi"}},{"cell_type":"markdown","source":"\nASHERE (American Society of Heating and Air-Conditioning Engineers) is a company that focuses on the energy efficiency and building systems in the industry. They launched a compition on Kaggle to find the best prediction model for energy consumption i the upcoming years for their invetmentsin energy efficiency.\n\nThey provided some data in the comption like the hourly consumption of 4 different energy types consumed in 16 different sites for a year duration. The compition requires from the contestants to predict the hourly consumption of these 4 energiesin the upcoming next 2 years.","metadata":{"id":"0s21TZMROe2Y"}},{"cell_type":"markdown","source":"## 1.2 Problem Statement :","metadata":{"id":"pEJRY0_nzuJU"}},{"cell_type":"markdown","source":"The problem at hand is to take the energy consumption reading for the 4 different energies ( meter 0 :Electricity , 1 : Chilled Water , 2 : steam, 3: Hotwater ) with the given information of building,weather data and meter-reading of a past year. The company uses these kind of prediction to give its invertors as idea on the right kind of investments to reduce the cost.","metadata":{"id":"i3NuQcYczuL9"}},{"cell_type":"markdown","source":"## 1.3 Sources/Useful Links","metadata":{"id":"aeVYeHILOmiF"}},{"cell_type":"markdown","source":"\n**Useful resourses:**\n\n1.   https://www.kaggle.com/corochann/ashrae-feather-format-for-fast-loading\n2.   https://www.kaggle.com/gemartin/load-data-reduce-memory-usage\n3.   https://medium.com/analytics-vidhya/ashrae-great-energy-predictor-iii-a-machine-learning-case-study-a01a67eb048d\n4.   https://medium.com/@chandanaroyal99/ashrae-great-energy-predictor-iii-case-study-66a25acd77f0\n\n\n","metadata":{"id":"nYpbqIaQOoqS"}},{"cell_type":"markdown","source":"# 2. Machine Learning Probelm\n","metadata":{"id":"dgu47NwezuOv"}},{"cell_type":"markdown","source":"## 2.1 Data\n","metadata":{"id":"k9bLKE03PTNX"}},{"cell_type":"markdown","source":"**train.csv:** \n  1. building_id - Foreign key for the building metadata.\n  2. meter - The meter id code. Read as {0: electricity, 1: chilledwater, 2: steam, 3: hotwater}. Not every building has all meter types.\n  2. timestamp - When the measurement was taken\nmeter_reading - The target variable. Energy consumption in kWh (or equivalent). Note that this is real data with measurement error, which we expect will impose a baseline level of modeling error.\n  3. site_id - Foreign key for the weather files.\n  4. building_id - Foreign key for training.csv\n  5. primary_use - Indicator of the primary category of activities for the building based on EnergyStar property type definitions\n  6. square_feet - Gross floor area of the building\n  7. year_built - Year building was opened\n  8. floor_count - Number of floors of the building\n\n\n**weather_[train/test].csv**: Weather data from a meteorological station as close as possible to the site.\n\n  1. site_id\n  2. air_temperature - Degrees Celsius\n  3. cloud_coverage - Portion of the sky covered in clouds, in oktas\n  4. dew_temperature - Degrees Celsius\n  5. precip_depth_1_hr - Millimeters\n  6. sea_level_pressure - Millibar/hectopascals\n  7. wind_direction - Compass direction (0-360)\n  8. wind_speed - Meters per second\n\n**test.csv**: The submission files use row numbers for ID codes in order to save space on the file uploads. test.csv has no feature data; it exists so you can get your predictions into the correct order.\n\n  1. row_id - Row id for your submission file\n  2. building_id - Building id code\n  3. meter - The meter id code\n  4. timestamp - Timestamps for the test data period\n  \n**sample_submission.csv**: A valid sample submission. \n  1. All floats in the solution file were truncated to four decimal places; we recommend you do the same to save space on your file upload.\n\n  2. There are gaps in some of the meter readings for both the train and test sets. Gaps in the test set are not revealed or scored.","metadata":{"id":"T7HI-y2JzuUU"}},{"cell_type":"markdown","source":"# 2.2 Type of Machine Leaning Problem","metadata":{"id":"7n_fcrtczuXO"}},{"cell_type":"markdown","source":"It is a Regression problem, given meter type used and weather of a building predict the meter reading.","metadata":{"id":"MjGBe6cAQ6cy"}},{"cell_type":"markdown","source":"# 2.3 Performance Metric","metadata":{"id":"3wkLaKl2Q918"}},{"cell_type":"markdown","source":"he evaluation metric for this competition is Root Mean Squared Logarithmic Error.\n\nThe RMSLE is calculated as\n\n![Screen Shot 2022-01-12 at 12.32.22 AM.png](data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAiAAAACkCAYAAACuN5X7AAAMbGlDQ1BJQ0MgUHJvZmlsZQAASImVVwdYU8kWnluSkJDQQpcSehNEagApIbQA0otgIySBhBJjQlCxo4sKrhURwYquiii2FRA7dmVR7H2xoKKsi7rYUHkTEtB1X/ne+b6598+ZM/8pdyb3HgA0P3AlkjxUC4B8cYE0ITyYMSYtnUF6ChCAASIwAO5cnkzCiouLBlAG73+XdzegNZSrzgquf87/V9HhC2Q8AJBxEGfyZbx8iI8DgK/lSaQFABAVeqspBRIFngOxrhQGCHG5Amcr8XYFzlTiwwM2SQlsiC8DoEblcqXZAGjcg3pGIS8b8mh8hthVzBeJAdAcDnEAT8jlQ6yIfXh+/iQFroTYHtpLIIbxAGbmd5zZf+PPHOLncrOHsDKvAVELEckkedxp/2dp/rfk58kHfdjCQRVKIxIU+cMa3sqdFKXAVIi7xZkxsYpaQ/xBxFfWHQCUIpRHJCvtUROejA3rB/QhduVzQ6IgNoE4TJwXE63SZ2aJwjgQw92CThUVcJIgNoR4oUAWmqiy2SidlKDyhTZkSdkslf4cVzrgV+HrgTw3maXifyMUcFT8mEaRMCkVYgrE1oWilBiINSB2keUmRqlsRhUJ2TGDNlJ5giJ+a4gTBOLwYCU/VpglDUtQ2ZfmywbzxTYKRZwYFd5XIEyKUNYHO8XjDsQPc8EuC8Ss5EEegWxM9GAufEFIqDJ37LlAnJyo4vkgKQhOUK7FKZK8OJU9binIC1foLSH2kBUmqtbiKQVwcyr58SxJQVySMk68KIcbGaeMB18GogEbhAAGkMORCSaBH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wDzEIAABCAAgSASQIAE0eu0GQIQgAAEIOAzAQSIzw7APAQgAAEIQCCIBBAgQfQ6bYYABCAAAQj4TAAB4rMDMA8BCEAAAhAIIgEESBC9TpshAAEIQAACPhNAgPjsAMxDAAIQgAAEgkgAARJEr9NmCEAAAhCAgM8EECA+OwDzEIAABCAAgSASQIAE0eu0GQIQgAAEIOAzAQSIzw7APAQgAAEIQCCIBBAgQfQ6bYYABCAAAQj4TAAB4rMDMA8BCEAAAhAIIgEESBC9TpshAAEIQAACPhNAgPjsAMxDAAIQgAAEgkgAARJEr9NmCEAAAhCAgM8EECA+OwDzEIAABCAAgSASQIAE0eu0GQIQgAAEIOAzAQSIzw7APAQgAAEIQCCIBBAgQfQ6bYYABCAAAQj4TAAB4rMDMA8BCEAAAhAIIgEESBC9TpshAAEIQAACPhNAgPjsAMxDAAIQgAAEgkgAARJEr9NmCEAAAhCAgM8EECA+OwDzEIAABCAAgSASQIAE0eu0GQIQgAAEIOAzAQSIzw7APAQgAAEIQCCIBBAgQfQ6bYYABCAAAQj4TAAB4rMDMA8BCEAAAhAIIgEESBC9TpshAAEIQAACPhNAgPjsAMxDAAIQgAAEgkgAARJEr9NmCEAAAhCAgM8EECA+OwDzEIAABCAAgSAS+B/rxlS5jcueoAAAAABJRU5ErkJggg==)","metadata":{"id":"YSvr9IYiRD0R"}},{"cell_type":"markdown","source":"# 3.Loading Data","metadata":{"id":"_3F6lPng_UJY"}},{"cell_type":"markdown","source":"## 3.1 Importing necessary libraries","metadata":{"id":"V1xIUKqK_mQn"}},{"cell_type":"code","source":"# Importing needed libraries to be used throughout the project\n\n%matplotlib inline\n\nimport pandas as pd\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport seaborn as sns\nimport os\n\nimport warnings\nwarnings.filterwarnings('ignore')\n\nimport os\nfor dirname, _, filenames in os.walk('/kaggle/input'):\n    for filename in filenames:\n        print(os.path.join(dirname, filename))","metadata":{"id":"5h4-2ayuABWJ","execution":{"iopub.status.busy":"2022-01-13T02:50:01.463976Z","iopub.execute_input":"2022-01-13T02:50:01.464284Z","iopub.status.idle":"2022-01-13T02:50:02.400996Z","shell.execute_reply.started":"2022-01-13T02:50:01.464254Z","shell.execute_reply":"2022-01-13T02:50:02.400168Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"## 3.2 Loading the ASHRAE dataset","metadata":{"id":"OPc_EXwyA9b6"}},{"cell_type":"code","source":"data_path = \"/kaggle/input/ashrae-energy-prediction/\"\n\ntrain_path = data_path + \"train.csv\"\ntest_path = data_path + \"test.csv\"\n\nbuilding_path = data_path + \"building_metadata.csv\"\n\nweather_train_path = data_path + \"weather_train.csv\"\nweather_test_path = data_path + \"weather_test.csv\"","metadata":{"execution":{"iopub.status.busy":"2022-01-13T02:50:05.868536Z","iopub.execute_input":"2022-01-13T02:50:05.869275Z","iopub.status.idle":"2022-01-13T02:50:05.873134Z","shell.execute_reply.started":"2022-01-13T02:50:05.869235Z","shell.execute_reply":"2022-01-13T02:50:05.872603Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"train_data = pd.read_csv(train_path)\ntest_data = pd.read_csv(test_path)\n\nbuilding_data = pd.read_csv(building_path)\n\nweather_train_data = pd.read_csv(weather_train_path)\nweather_test_data = pd.read_csv(weather_test_path)","metadata":{"execution":{"iopub.status.busy":"2022-01-13T02:50:07.681918Z","iopub.execute_input":"2022-01-13T02:50:07.682368Z","iopub.status.idle":"2022-01-13T02:50:52.932485Z","shell.execute_reply.started":"2022-01-13T02:50:07.682338Z","shell.execute_reply":"2022-01-13T02:50:52.931615Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"## 3.3 Viewing Snippets of the dataset","metadata":{"id":"dA-tM7adC1qE"}},{"cell_type":"code","source":"train_data.head()","metadata":{"id":"1D1_O4xTdSZC","outputId":"b5af01d4-143e-42a5-9dae-95261582357e","execution":{"iopub.status.busy":"2022-01-13T02:51:01.75553Z","iopub.execute_input":"2022-01-13T02:51:01.75599Z","iopub.status.idle":"2022-01-13T02:51:01.776908Z","shell.execute_reply.started":"2022-01-13T02:51:01.75595Z","shell.execute_reply":"2022-01-13T02:51:01.776138Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"train_data.describe()","metadata":{"id":"TkzrBkTCfc91","outputId":"98579d23-0a7e-43c3-a460-e7073b07471c","execution":{"iopub.status.busy":"2022-01-13T02:51:03.669905Z","iopub.execute_input":"2022-01-13T02:51:03.670511Z","iopub.status.idle":"2022-01-13T02:51:05.547133Z","shell.execute_reply.started":"2022-01-13T02:51:03.670464Z","shell.execute_reply":"2022-01-13T02:51:05.545868Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"train_data.info()","metadata":{"id":"AMzzogOkffvC","outputId":"76a3a107-d3cc-4a92-e9be-72182e01fcdb","execution":{"iopub.status.busy":"2022-01-13T02:51:06.996407Z","iopub.execute_input":"2022-01-13T02:51:06.99687Z","iopub.status.idle":"2022-01-13T02:51:07.009247Z","shell.execute_reply.started":"2022-01-13T02:51:06.996825Z","shell.execute_reply":"2022-01-13T02:51:07.008599Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"test_data.head()","metadata":{"id":"-T-QEb-wgVP2","outputId":"773c52c2-1557-4b2f-93f8-0462b93ee4f4","execution":{"iopub.status.busy":"2022-01-13T02:51:08.555067Z","iopub.execute_input":"2022-01-13T02:51:08.555669Z","iopub.status.idle":"2022-01-13T02:51:08.56545Z","shell.execute_reply.started":"2022-01-13T02:51:08.555633Z","shell.execute_reply":"2022-01-13T02:51:08.564927Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"building_data.head()","metadata":{"id":"gMQBd4qygVaq","outputId":"2fb7afd6-cefc-41bc-ce54-7c2f6cb52028","execution":{"iopub.status.busy":"2022-01-13T02:51:10.035508Z","iopub.execute_input":"2022-01-13T02:51:10.035996Z","iopub.status.idle":"2022-01-13T02:51:10.046543Z","shell.execute_reply.started":"2022-01-13T02:51:10.035963Z","shell.execute_reply":"2022-01-13T02:51:10.04577Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"weather_train_data.head()","metadata":{"id":"otkw-wUhgVjt","outputId":"9c1c5574-b1ff-49cd-c964-414ce37b675e","execution":{"iopub.status.busy":"2022-01-13T02:51:11.270615Z","iopub.execute_input":"2022-01-13T02:51:11.271125Z","iopub.status.idle":"2022-01-13T02:51:11.287454Z","shell.execute_reply.started":"2022-01-13T02:51:11.271091Z","shell.execute_reply":"2022-01-13T02:51:11.28669Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"weather_test_data.head()","metadata":{"id":"h0-z2ilbgVnQ","outputId":"8c87e1d0-3ead-4c4b-ad20-4016f1b868ca","execution":{"iopub.status.busy":"2022-01-13T02:51:12.530876Z","iopub.execute_input":"2022-01-13T02:51:12.531737Z","iopub.status.idle":"2022-01-13T02:51:12.54891Z","shell.execute_reply.started":"2022-01-13T02:51:12.531687Z","shell.execute_reply":"2022-01-13T02:51:12.5481Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"print('Shape of Train Data:',train_data.shape)\nprint('Shape of Test Data:', test_data.shape)\nprint('Shape of Building Data:', building_data.shape)\nprint('Shape of Weather Train Data:', weather_train_data.shape)\nprint('Shape of Weather Test Data:', weather_test_data.shape)","metadata":{"id":"ZVRDsT9DgVwN","outputId":"03ad0760-febe-4b19-d0b2-af878b16f5de","execution":{"iopub.status.busy":"2022-01-13T02:51:13.791058Z","iopub.execute_input":"2022-01-13T02:51:13.791591Z","iopub.status.idle":"2022-01-13T02:51:13.797551Z","shell.execute_reply.started":"2022-01-13T02:51:13.791536Z","shell.execute_reply":"2022-01-13T02:51:13.797049Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"## 3.4 Converting data to feather format for faster loading","metadata":{"id":"QGVsN_e6I_mU"}},{"cell_type":"code","source":"# Converting data into feather format since some dataframes are too large and take a long time to load\n# This method is inspired from the kaggle notebook titled: ASHRAE: feather format for fast loading\n# Which is found at: https://www.kaggle.com/corochann/ashrae-feather-format-for-fast-loading\n\ntrain_data.to_feather('train_data.feather')\ntest_data.to_feather('test_data.feather')\n\nbuilding_data.to_feather('building_data.feather')\n\nweather_train_data.to_feather('weather_train_data.feather')\nweather_test_data.to_feather('weather_test_data.feather')\n","metadata":{"id":"W3dUkNtVeSfP","execution":{"iopub.status.busy":"2022-01-13T02:51:17.90172Z","iopub.execute_input":"2022-01-13T02:51:17.902078Z","iopub.status.idle":"2022-01-13T02:51:24.781717Z","shell.execute_reply.started":"2022-01-13T02:51:17.902041Z","shell.execute_reply":"2022-01-13T02:51:24.780889Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"train_data = pd.read_feather('train_data.feather')\ntest_data = pd.read_feather('test_data.feather')\n\nbuilding_data = pd.read_feather('building_data.feather')\n\nweather_train_data = pd.read_feather('weather_train_data.feather')\nweather_test_data = pd.read_feather('weather_test_data.feather')\n","metadata":{"id":"K-xSJPieegWJ","execution":{"iopub.status.busy":"2022-01-13T02:51:30.646478Z","iopub.execute_input":"2022-01-13T02:51:30.647035Z","iopub.status.idle":"2022-01-13T02:51:34.401509Z","shell.execute_reply.started":"2022-01-13T02:51:30.646994Z","shell.execute_reply":"2022-01-13T02:51:34.400761Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"## 3.5 Reducing the memory usage of the data","metadata":{"id":"la1s0NjRJvGK"}},{"cell_type":"code","source":"# This function helps in optimizing the memory used by the dataframes by by modifying/altering thedatatype of each column.\n# This method is inspired from the kaggle notebook titled: load data (reduce memory usage)\n# Which is found at: https://www.kaggle.com/gemartin/load-data-reduce-memory-usage\n\ndef reduce_mem_usage(df, df_name):\n\n    start_mem = df.memory_usage().sum() / 1024**2\n    \n    for col in df.columns:\n\n        col_type = df[col].dtype\n\n        if col_type != object:\n            c_min = df[col].min()\n            c_max = df[col].max()\n            if str(col_type)[:3] == 'int':\n                if c_min > np.iinfo(np.int8).min and c_max < np.iinfo(np.int8).max:\n                    df[col] = df[col].astype(np.int8)\n                elif c_min > np.iinfo(np.int16).min and c_max < np.iinfo(np.int16).max:\n                    df[col] = df[col].astype(np.int16)\n                elif c_min > np.iinfo(np.int32).min and c_max < np.iinfo(np.int32).max:\n                    df[col] = df[col].astype(np.int32)\n                elif c_min > np.iinfo(np.int64).min and c_max < np.iinfo(np.int64).max:\n                    df[col] = df[col].astype(np.int64)  \n            else:\n                if c_min > np.finfo(np.float16).min and c_max < np.finfo(np.float16).max:\n                    df[col] = df[col].astype(np.float16)\n                elif c_min > np.finfo(np.float32).min and c_max < np.finfo(np.float32).max:\n                    df[col] = df[col].astype(np.float32)\n                else:\n                    df[col] = df[col].astype(np.float64)\n        else:\n            df[col] = df[col].astype('category')\n\n    end_mem = df.memory_usage().sum() / 1024**2\n\n    print('Memory usage of {} is reduced by {:.2f} %. Usage dropped from {:.2f} MB to {:.2f} MB.'.format(df_name, (100 * (start_mem - end_mem) / start_mem), start_mem, end_mem))\n    \n    return df\n","metadata":{"id":"v3yIjOevKKKY","execution":{"iopub.status.busy":"2022-01-13T02:51:37.898309Z","iopub.execute_input":"2022-01-13T02:51:37.899112Z","iopub.status.idle":"2022-01-13T02:51:37.914236Z","shell.execute_reply.started":"2022-01-13T02:51:37.899039Z","shell.execute_reply":"2022-01-13T02:51:37.913371Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"train_data = reduce_mem_usage(train_data, 'Train Data')\ntest_data = reduce_mem_usage(test_data, 'Test Data')\n\nbuilding_data = reduce_mem_usage(building_data, 'Building Data')\n\nweather_train_data = reduce_mem_usage(weather_train_data, 'Weather Train Data')\nweather_test_data = reduce_mem_usage(weather_test_data, 'Weather Test Data')","metadata":{"id":"XYZL4jkJeVyB","outputId":"01e04941-ed2c-47a7-d13f-80fe439f5148","execution":{"iopub.status.busy":"2022-01-13T02:51:40.708106Z","iopub.execute_input":"2022-01-13T02:51:40.708389Z","iopub.status.idle":"2022-01-13T02:51:49.288774Z","shell.execute_reply.started":"2022-01-13T02:51:40.70836Z","shell.execute_reply":"2022-01-13T02:51:49.28802Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"## 3.6 Merging Data","metadata":{"id":"wx3NXRmzYLKW"}},{"cell_type":"code","source":"train = train_data.merge(building_data, on='building_id', how='left')\ntrain = train.merge(weather_train_data, on=['site_id', 'timestamp'], how='left')","metadata":{"id":"y67TusNcgV3a","execution":{"iopub.status.busy":"2022-01-13T02:51:55.055413Z","iopub.execute_input":"2022-01-13T02:51:55.055699Z","iopub.status.idle":"2022-01-13T02:52:01.450785Z","shell.execute_reply.started":"2022-01-13T02:51:55.05567Z","shell.execute_reply":"2022-01-13T02:52:01.449825Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"test = test_data.merge(building_data, on='building_id', how='left')\ntest = test.merge(weather_test_data, on=['site_id', 'timestamp'], how='left')","metadata":{"id":"HuCZexpsu6B-","execution":{"iopub.status.busy":"2022-01-13T02:52:04.602089Z","iopub.execute_input":"2022-01-13T02:52:04.602682Z","iopub.status.idle":"2022-01-13T02:52:21.883662Z","shell.execute_reply.started":"2022-01-13T02:52:04.602634Z","shell.execute_reply":"2022-01-13T02:52:21.882128Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"train.head()","metadata":{"id":"B9S_mqqQgV_c","outputId":"0a3856dd-d5b5-477f-a284-a13e18045942","execution":{"iopub.status.busy":"2022-01-13T02:53:26.37233Z","iopub.execute_input":"2022-01-13T02:53:26.373038Z","iopub.status.idle":"2022-01-13T02:53:26.403184Z","shell.execute_reply.started":"2022-01-13T02:53:26.372998Z","shell.execute_reply":"2022-01-13T02:53:26.402263Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"test.head()","metadata":{"id":"S2d5l8RXuyHG","outputId":"31ceb6f9-55ed-4aca-e4cd-6f5159a029f0","execution":{"iopub.status.busy":"2022-01-13T02:53:27.841901Z","iopub.execute_input":"2022-01-13T02:53:27.84219Z","iopub.status.idle":"2022-01-13T02:53:27.865219Z","shell.execute_reply.started":"2022-01-13T02:53:27.84216Z","shell.execute_reply":"2022-01-13T02:53:27.864395Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"print('Shape of Combined Train Data:',train.shape)\nprint('Shape of Combined Test Data:', test.shape)","metadata":{"id":"K3ZB7cWCuyUs","outputId":"d0cbc807-60f4-4ecd-fa97-ce0d459bfb4b","execution":{"iopub.status.busy":"2022-01-13T02:53:29.183808Z","iopub.execute_input":"2022-01-13T02:53:29.184708Z","iopub.status.idle":"2022-01-13T02:53:29.18971Z","shell.execute_reply.started":"2022-01-13T02:53:29.184663Z","shell.execute_reply":"2022-01-13T02:53:29.18888Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"## 3.7 Breaking Timestamp into Hour, Day, Month, Year","metadata":{"id":"26TNI9o2Bmld"}},{"cell_type":"code","source":"# This function firstly converts timestamp to date and then breaks down date into 6 new columns: hour, day, dayOfWeek, dayOfYear, month and year\n\ndef breakdown_timestamp(dataframe):\n    \n    dataframe['timestamp']= pd.to_datetime(dataframe['timestamp'])\n\n    dataframe['hour']= np.uint8(dataframe['timestamp'].dt.hour)\n    \n    dataframe['day']= np.uint16(dataframe['timestamp'].dt.day)\n    dataframe['dayofweek']= np.uint8(dataframe['timestamp'].dt.dayofweek)\n    dataframe['dayofyear']= np.uint16(dataframe['timestamp'].dt.dayofyear)\n\n    dataframe['month']= np.uint8(dataframe['timestamp'].dt.month)\n\n    dataframe['year']= np.uint16(dataframe['timestamp'].dt.year)\n    \n    return dataframe","metadata":{"id":"6A03K8Z5uydO","execution":{"iopub.status.busy":"2022-01-13T02:53:33.284135Z","iopub.execute_input":"2022-01-13T02:53:33.284633Z","iopub.status.idle":"2022-01-13T02:53:33.292746Z","shell.execute_reply.started":"2022-01-13T02:53:33.284584Z","shell.execute_reply":"2022-01-13T02:53:33.291867Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"train = breakdown_timestamp(train)\ntest = breakdown_timestamp(test)","metadata":{"id":"0H9LBPwzuylB","execution":{"iopub.status.busy":"2022-01-13T02:53:35.362217Z","iopub.execute_input":"2022-01-13T02:53:35.36251Z","iopub.status.idle":"2022-01-13T02:54:13.91624Z","shell.execute_reply.started":"2022-01-13T02:53:35.362475Z","shell.execute_reply":"2022-01-13T02:54:13.915283Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"print('New Shape of Train Data:',train.shape)\nprint('New Shape of Test Data:', test.shape)","metadata":{"id":"ucraKBPxIltX","outputId":"0dfc5e90-512d-48da-873d-68a175deff8a","execution":{"iopub.status.busy":"2022-01-13T02:54:22.139738Z","iopub.execute_input":"2022-01-13T02:54:22.140335Z","iopub.status.idle":"2022-01-13T02:54:22.146453Z","shell.execute_reply.started":"2022-01-13T02:54:22.140287Z","shell.execute_reply":"2022-01-13T02:54:22.145504Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"# 4. EDA","metadata":{"id":"PcV2YHyy1Ahf"}},{"cell_type":"markdown","source":"## 4.1 Exploring the Target Value 'Meter Reading'","metadata":{"id":"2OvLGJ01wbGO"}},{"cell_type":"code","source":"# This Function Draws the distribution plot for the column passed into the function's arguments\n\nsns.set_theme()\n\ndef draw_distribution_graph(dataframe, column_name):\n    \n    fig, ax = plt.subplots(figsize=(8, 8))\n    sns.distplot(dataframe[column_name], color='purple', ax = ax).set_title(\"Distribution Graph for {}\".format(column_name), fontsize=16)\n    plt.xlabel(column_name, fontsize=12)\n    plt.ylabel('Density', fontsize=12)\n    plt.show()","metadata":{"id":"yzfbUkiduzJH","execution":{"iopub.status.busy":"2022-01-13T02:54:25.932858Z","iopub.execute_input":"2022-01-13T02:54:25.933292Z","iopub.status.idle":"2022-01-13T02:54:25.941622Z","shell.execute_reply.started":"2022-01-13T02:54:25.933244Z","shell.execute_reply":"2022-01-13T02:54:25.940588Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"draw_distribution_graph(train, 'meter_reading')","metadata":{"papermill":{"duration":119.03588,"end_time":"2022-01-09T19:16:26.547542","exception":false,"start_time":"2022-01-09T19:14:27.511662","status":"completed"},"tags":[],"id":"26883b96","outputId":"aaa02099-ed72-490f-be7c-cd1c33d8c408","execution":{"iopub.status.busy":"2022-01-13T02:54:29.027949Z","iopub.execute_input":"2022-01-13T02:54:29.028975Z","iopub.status.idle":"2022-01-13T02:55:37.827335Z","shell.execute_reply.started":"2022-01-13T02:54:29.028932Z","shell.execute_reply":"2022-01-13T02:55:37.82631Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"print('Meter Reading has a skewness of', train['meter_reading'].skew())","metadata":{"papermill":{"duration":0.26533,"end_time":"2022-01-09T19:16:26.951423","exception":false,"start_time":"2022-01-09T19:16:26.686093","status":"completed"},"tags":[],"id":"50922d05","outputId":"e473a548-b4f0-4f03-c0eb-60fe71da68f1","execution":{"iopub.status.busy":"2022-01-13T02:55:44.674483Z","iopub.execute_input":"2022-01-13T02:55:44.675281Z","iopub.status.idle":"2022-01-13T02:55:44.905973Z","shell.execute_reply.started":"2022-01-13T02:55:44.67524Z","shell.execute_reply":"2022-01-13T02:55:44.90511Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. The Meter Reading is extremely skewed to the left.\n2. We need to apply log tranformation to fix the skewness.\n","metadata":{"papermill":{"duration":0.03366,"end_time":"2022-01-09T19:16:27.019201","exception":false,"start_time":"2022-01-09T19:16:26.985541","status":"completed"},"tags":[],"id":"d075eb6f"}},{"cell_type":"code","source":"train['meter_reading']=np.log1p(train['meter_reading'])","metadata":{"papermill":{"duration":0.43745,"end_time":"2022-01-09T19:16:27.491494","exception":false,"start_time":"2022-01-09T19:16:27.054044","status":"completed"},"tags":[],"id":"abfa1395","execution":{"iopub.status.busy":"2022-01-13T02:55:48.536459Z","iopub.execute_input":"2022-01-13T02:55:48.536937Z","iopub.status.idle":"2022-01-13T02:55:48.955342Z","shell.execute_reply.started":"2022-01-13T02:55:48.536885Z","shell.execute_reply":"2022-01-13T02:55:48.954649Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"draw_distribution_graph(train, 'meter_reading')","metadata":{"execution":{"iopub.status.busy":"2022-01-13T02:55:54.009962Z","iopub.execute_input":"2022-01-13T02:55:54.010436Z","iopub.status.idle":"2022-01-13T02:57:09.802681Z","shell.execute_reply.started":"2022-01-13T02:55:54.010387Z","shell.execute_reply":"2022-01-13T02:57:09.799572Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"print('Meter Reading has a new skewness of', train['meter_reading'].skew())","metadata":{"papermill":{"duration":0.252567,"end_time":"2022-01-09T19:16:27.77802","exception":false,"start_time":"2022-01-09T19:16:27.525453","status":"completed"},"tags":[],"id":"6463a672","outputId":"f08000e8-06ea-4c9a-8356-401e4153815c","execution":{"iopub.status.busy":"2022-01-13T02:57:42.008115Z","iopub.execute_input":"2022-01-13T02:57:42.00847Z","iopub.status.idle":"2022-01-13T02:57:42.240187Z","shell.execute_reply.started":"2022-01-13T02:57:42.008432Z","shell.execute_reply":"2022-01-13T02:57:42.239261Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n- The most recurrent meter reading is zero. (This will be taken care of in the data preperation section)\n","metadata":{"id":"rRWy6SpC09AK"}},{"cell_type":"markdown","source":"## 4.2 Exploring Different Meter Types","metadata":{"id":"b8BxGPDe2COq"}},{"cell_type":"code","source":"fig, ax = plt.subplots(figsize=(8,8))\nmeter_types_labels = ['Electricity', 'Chilled Water', 'Steam', 'Hot Water']\nsns.countplot(x = 'meter', data = train).set_title(\"Frequency of Readings by the Different Meter Types\", fontsize=16)\nax.set_xticklabels(meter_types_labels)\nplt.xlabel('Meter Type', fontsize=12)\nplt.ylabel('Readings Count', fontsize=12)\nplt.show()","metadata":{"id":"cQAUO2dL4umZ","outputId":"5756f5bc-5db7-4da6-c5a3-721d87adf734","execution":{"iopub.status.busy":"2022-01-13T02:57:47.717299Z","iopub.execute_input":"2022-01-13T02:57:47.717612Z","iopub.status.idle":"2022-01-13T02:57:49.313539Z","shell.execute_reply.started":"2022-01-13T02:57:47.717577Z","shell.execute_reply":"2022-01-13T02:57:49.312774Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. Electricity meters are the most meters used in buildings. \n2. Hot Water meters are the least used in buildings.\n","metadata":{"id":"gE_gGce1ABGd"}},{"cell_type":"code","source":"# Making a copy of the dataset to group by meter type\n\nfig, ax = plt.subplots(figsize=(8,8))\nmeter_types = train.groupby('meter').meter_reading.mean().reset_index()\nsns.barplot(x ='meter', y ='meter_reading', data = meter_types).set_title(\"Average Log Reading for Each Meter Type\", fontsize=16)\nax.set_xticklabels(meter_types_labels)\nplt.xlabel('Meter Type', fontsize=12)\nplt.ylabel('Average Log Reading', fontsize=12)\nplt.show()","metadata":{"id":"0X7263bW6xuY","outputId":"aab9a405-9b82-4286-e19c-0c55a6a7c40f","execution":{"iopub.status.busy":"2022-01-13T02:57:53.767481Z","iopub.execute_input":"2022-01-13T02:57:53.768118Z","iopub.status.idle":"2022-01-13T02:57:54.429421Z","shell.execute_reply.started":"2022-01-13T02:57:53.768077Z","shell.execute_reply":"2022-01-13T02:57:54.428498Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. Steam meters consume the most energy and thus are the least energy efficient out of the 4 meter types.\n2. Hot Water meters consume the least energy.\n","metadata":{"id":"Zcw7prjEACoL"}},{"cell_type":"markdown","source":"## 4.3 Exploring Frequency of the Different Primary Use Categories ","metadata":{"id":"4pPN7uAFE43d"}},{"cell_type":"code","source":"plt.figure(figsize=(8,8))\nsns.countplot(x = 'primary_use', data = train).set_title(\"Frequency of Primary Use Categories\", fontsize=16)\nplt.xticks(rotation=90)\nplt.xlabel('Primary Use Category', fontsize=12)\nplt.ylabel('Count', fontsize=12)\nplt.show()","metadata":{"id":"d4FQAelWFYbX","outputId":"47316ff2-b4a6-4999-97e9-5061c2b7c90a","execution":{"iopub.status.busy":"2022-01-13T02:57:59.201986Z","iopub.execute_input":"2022-01-13T02:57:59.203924Z","iopub.status.idle":"2022-01-13T02:58:00.040575Z","shell.execute_reply.started":"2022-01-13T02:57:59.203888Z","shell.execute_reply":"2022-01-13T02:58:00.039612Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. Educational buildings contribute the largest number of readings. \n2. Religious worships contribute the least readings.","metadata":{"id":"HFc_w4PqI8tF"}},{"cell_type":"markdown","source":"## 4.4 Exploring Average Meter Reading Per Site and Use Category","metadata":{"id":"afQwvH2xJvgI"}},{"cell_type":"code","source":"site_use_grouping = train.groupby(['site_id','primary_use'])['meter_reading'].mean().unstack('primary_use')\nsite_use_grouping.plot(kind = 'bar', stacked = True, figsize=(18,10)).set_title(\"Average Log Meter Reading per site and use category\")\nplt.xlabel('Site Id')\nplt.ylabel('Log Meter Reading')\nplt.legend(loc = \"upper left\")\nplt.show()","metadata":{"id":"pQj7SEjoJzYm","outputId":"35cf5f7a-154d-4ed8-9a2a-ec27bb8d3195","execution":{"iopub.status.busy":"2022-01-13T02:58:04.4965Z","iopub.execute_input":"2022-01-13T02:58:04.497193Z","iopub.status.idle":"2022-01-13T02:58:06.539587Z","shell.execute_reply.started":"2022-01-13T02:58:04.497157Z","shell.execute_reply":"2022-01-13T02:58:06.538793Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. Site 13 has the highest average meter readings.\n2. Site 11 has the least average meter readings and buildings in this site are primarily used as educational institutions.","metadata":{"id":"upKhwnO-O71o"}},{"cell_type":"markdown","source":"## 4.5 Exploring Average Readings per Hour and Month","metadata":{"id":"ZTC2CeSvPwmv"}},{"cell_type":"code","source":"hour_groups = train.groupby(['timestamp','hour']).meter_reading.mean().reset_index()\nmonth_groups = train.groupby(['timestamp','month']).meter_reading.mean().reset_index()\n\nfig, (ax1, ax2) = plt.subplots(1, 2, figsize = (20,8))\nfig.suptitle('Average Readings According to Hour and Month')\n\nsns.lineplot(x = hour_groups['hour'], y = hour_groups['meter_reading'], color='green', ax = ax1)\nax1.set_title('Average Reading According to Hour')\n\n\nsns.lineplot(x = month_groups['month'], y = month_groups['meter_reading'], color='purple', ax = ax2)\nax2.set_title('Average Reading According to Month')\n\nplt.show()","metadata":{"id":"ye7un9MPRDM0","outputId":"6aca14f6-bd69-4f4d-b8f4-e67f52a9f5e9","execution":{"iopub.status.busy":"2022-01-13T02:58:11.892056Z","iopub.execute_input":"2022-01-13T02:58:11.892324Z","iopub.status.idle":"2022-01-13T02:58:19.587006Z","shell.execute_reply.started":"2022-01-13T02:58:11.892295Z","shell.execute_reply":"2022-01-13T02:58:19.586281Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. Energy consumption drops in the early hours of the morning around 3-4am and rises again after 5am.\n2. The hourly usage is maximized in the duration of 12-3pm, peeking at 1 in the afternoon Which is a logical conclusion as many instituitions work around this period.\n3. Energy Consumption is minimal during the period of January to March, reaching its lowest in March.\n4. Consumption starts rising gradually from April and reaches a peek in August.\n","metadata":{"id":"WfXJ4JF3U-Tl"}},{"cell_type":"markdown","source":"##  4.6 Exploring Average Readings per Building","metadata":{"papermill":{"duration":0.035927,"end_time":"2022-01-09T19:18:30.589484","exception":false,"start_time":"2022-01-09T19:18:30.553557","status":"completed"},"tags":[],"id":"00bf4e86"}},{"cell_type":"code","source":"building_groups = train.groupby(['building_id']).meter_reading.mean().reset_index()\n\nplt.figure(figsize=(8,8))\nsns.lineplot(x = building_groups['building_id'], y = building_groups.meter_reading).set_title(\"Average Log Meter Reading According to Building Id\", fontsize=16)\nplt.xlabel('Building Id', fontsize=12)\nplt.ylabel('Average Log Meter Reading', fontsize=12)\nplt.xticks(rotation=45)\nplt.show()","metadata":{"id":"Q8_1n7rpd-f9","outputId":"7d74d5c0-880c-4474-f266-65c0df8ea2a4","execution":{"iopub.status.busy":"2022-01-13T02:58:24.062109Z","iopub.execute_input":"2022-01-13T02:58:24.062737Z","iopub.status.idle":"2022-01-13T02:58:24.825051Z","shell.execute_reply.started":"2022-01-13T02:58:24.062699Z","shell.execute_reply":"2022-01-13T02:58:24.824284Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"##  4.7 Checking Missing Values","metadata":{"id":"-96cGhcRfe66"}},{"cell_type":"code","source":"missing_values = pd.DataFrame(train.isnull().sum() * 100 / len(train))\nmissing_values.columns = [\"Missing Values\"]\n\nmissing_values = missing_values[missing_values[\"Missing Values\"] != 0]\nmissing_values.sort_values(by = \"Missing Values\", axis = 0, ascending = False, inplace = True)\n\nmissing_values","metadata":{"id":"M4lzM1VY0-LI","outputId":"6f8d18cf-c628-48c4-c44d-d9c959ea4641","execution":{"iopub.status.busy":"2022-01-13T02:58:32.163193Z","iopub.execute_input":"2022-01-13T02:58:32.163738Z","iopub.status.idle":"2022-01-13T02:58:33.433406Z","shell.execute_reply.started":"2022-01-13T02:58:32.163701Z","shell.execute_reply":"2022-01-13T02:58:33.432627Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"plt.figure(figsize=(8,8))\nsns.barplot(x = missing_values['Missing Values'], y = missing_values.index).set_title(\"Missing Value Percentage Per Feature\", fontsize=16)\nplt.xlabel('Percentage Missing', fontsize=12)\nplt.ylabel('Feature', fontsize=12)\nplt.show()","metadata":{"id":"YUnOv7nRgpWz","outputId":"6b52dbfc-9a9b-4bd8-96e5-d6f0be707f76","execution":{"iopub.status.busy":"2022-01-13T02:58:34.651173Z","iopub.execute_input":"2022-01-13T02:58:34.651953Z","iopub.status.idle":"2022-01-13T02:58:35.065283Z","shell.execute_reply.started":"2022-01-13T02:58:34.651912Z","shell.execute_reply":"2022-01-13T02:58:35.064514Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. Floor count has the highest number of missing values, with a percentage reaching 82.6 %.\n2. Year Built is the second leading column in missing values with almost 60% of the data being null.\n3. This needs to be taken care of during the data preparation process before feeding it to the models for training.","metadata":{"id":"Dv5M7_QwiYLN"}},{"cell_type":"markdown","source":"## 4.8 Visualizing Correlation Between the Different Features ","metadata":{"id":"_WpTdXXCjbQX"}},{"cell_type":"code","source":"correlation_matrix = train.corr()","metadata":{"id":"xndE1p7mlwb3","execution":{"iopub.status.busy":"2022-01-12T22:58:57.775802Z","iopub.execute_input":"2022-01-12T22:58:57.776127Z","iopub.status.idle":"2022-01-12T22:59:25.381842Z","shell.execute_reply.started":"2022-01-12T22:58:57.776093Z","shell.execute_reply":"2022-01-12T22:59:25.380657Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"plt.figure(figsize=(18,18))\nsns.heatmap(correlation_matrix, annot = True, vmin = -1, vmax = 1, cmap = \"YlGnBu\").set_title('Correlation Matrix')\nplt.show()","metadata":{"id":"AB3i9pjZ4X0V","outputId":"f0204369-9ace-4dec-f888-1e82554f9316","execution":{"iopub.status.busy":"2022-01-12T22:59:33.690258Z","iopub.execute_input":"2022-01-12T22:59:33.69056Z","iopub.status.idle":"2022-01-12T22:59:35.700701Z","shell.execute_reply.started":"2022-01-12T22:59:33.690525Z","shell.execute_reply":"2022-01-12T22:59:35.699587Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"target_corr_df = pd.DataFrame(correlation_matrix[\"meter_reading\"].sort_values(ascending=False))\ntarget_corr_df ","metadata":{"id":"j_Yz9ARQmPpO","outputId":"4824d4eb-2afe-47b5-dff4-72d12a758f91","execution":{"iopub.status.busy":"2022-01-12T22:59:42.447181Z","iopub.execute_input":"2022-01-12T22:59:42.448424Z","iopub.status.idle":"2022-01-12T22:59:42.462751Z","shell.execute_reply.started":"2022-01-12T22:59:42.448375Z","shell.execute_reply":"2022-01-12T22:59:42.461898Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n1. Site Id is extremely correlated with the Building Id (Correlation of 1).\n2. Drew Tempreture and Air Tempreture have the second highest correlation, with a correlation of 0.8.\n3. No features have a strong correlation with the target value 'Meter Reading'.","metadata":{"id":"c322uqnNkENt"}},{"cell_type":"markdown","source":"## 4.9  Visualizing Features Histograms","metadata":{"id":"GPEWR1r0niiP"}},{"cell_type":"code","source":"train.hist(bins=50, figsize=(24,15))\nplt.suptitle('Histograms For the Different Features', fontsize=16)\nplt.show()","metadata":{"id":"N17KxP1wsTVd","outputId":"452130af-d6d2-4f3e-f477-b7d42c8f3359","execution":{"iopub.status.busy":"2022-01-12T22:59:50.372006Z","iopub.execute_input":"2022-01-12T22:59:50.372369Z","iopub.status.idle":"2022-01-12T23:00:16.021555Z","shell.execute_reply.started":"2022-01-12T22:59:50.372332Z","shell.execute_reply":"2022-01-12T23:00:16.020313Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"markdown","source":"**Observations:**\n- Square Feet is heavily skewed to the left, therefore, we need to apply log transformation to fix that.","metadata":{"id":"yXkdKSi_zEN1"}},{"cell_type":"code","source":"fig, (ax1, ax2) = plt.subplots(1, 2, figsize = (20,8))\nfig.suptitle('Square Feet Before and After Fixing Skewness')\n\nsns.distplot(train['square_feet'], color='purple', ax = ax1)\nax1.set_title('Distribution Plot before Log Transformation')\n\nsns.distplot(np.log1p(train['square_feet']), color='purple', ax = ax2)\nax2.set_title('Distribution Plot after Log Transformation')\n\nplt.show()","metadata":{"id":"HwYIOO-uvXBL","outputId":"accd042e-a6f9-472d-c978-0945af37b28b","execution":{"iopub.status.busy":"2022-01-12T23:00:24.886375Z","iopub.execute_input":"2022-01-12T23:00:24.886845Z","iopub.status.idle":"2022-01-12T23:02:59.511323Z","shell.execute_reply.started":"2022-01-12T23:00:24.886792Z","shell.execute_reply":"2022-01-12T23:02:59.510169Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"print('Square Feet skewness before Log Transformation is: ', train['square_feet'].skew())\n\ntrain['square_feet'] = np.log1p(train['square_feet'])\nprint('Square Feet skewness after Log Transformation is: ', train['square_feet'].skew())","metadata":{"id":"kGOBwLjJ-cv0","outputId":"4d548e6b-1db1-4372-8d9b-3c6164911a1b","execution":{"iopub.status.busy":"2022-01-13T01:31:06.338395Z","iopub.execute_input":"2022-01-13T01:31:06.338899Z","iopub.status.idle":"2022-01-13T01:31:07.426805Z","shell.execute_reply.started":"2022-01-13T01:31:06.338848Z","shell.execute_reply":"2022-01-13T01:31:07.42572Z"},"trusted":true},"execution_count":null,"outputs":[]}]}