application_vnd.jupyter.stderr_output_1.png
from sklearn import preprocessing

from sklearn import preprocessing

import matplotlib.pyplot as plt

import pandas as pd

import seaborn as sns

data = pd.read_csv('../input/house-rent-prediction-dataset/House_Rent_Dataset.csv')
data

data.isnull().sum()

data['Posted_On'] = pd.to_datetime(data['Posted_On'])
data['Posted_On'].dtypes

data = data.drop('Posted On', axis=True)
data

data.dtypes

data = data.drop(['Floor', 'Area Type', 'Area Locality'], axis=1)
data

from sklearn import preprocessing
lb = preprocessing.LabelEncoder()
data = data.apply(lb.fit_transform)

data = pd.get_dummies(data, columns=['City'], drop_first=True)

x = data.drop('Rent', axis=1)
y = data['Rent']

from sklearn import preprocessing
scaler = preprocessing.StandardScaler()
x = scaler.fit_transform(x)
x = pd.DataFrame(x)
x