<jupyter_start><jupyter_text>For normalization I used MinMaxScaler, where every features is changed into range 0-1<jupyter_code>df_train = pd.read_csv('./5.complete_train.csv')
df_test = pd.read_csv('./5.complete_test.csv')
print(df_train.shape)
print(df_test.shape)
df_merge_data = pd.concat([df_train,df_test])
print(df_merge_data.shape)
y = df_merge_data["Best Performance"] #label
df_merge_data.drop(['Best Performance'], inplace=True, axis=1)
attr_names = list(df_merge_data.columns.values) 
print(attr_names)
df_merge_data.head()
x = df_merge_data.loc[:].values
print(x)
min_max_scaler = MinMaxScaler()
X_train_minmax = min_max_scaler.fit_transform(x)
print(X_train_minmax)
normalised_data = pd.DataFrame(X_train_minmax,columns=attr_names)
normalised_data.shape
y.shape
normalised_data.head()
y.head()
normalised_data.reset_index(drop=True, inplace=True)
y.reset_index(drop=True, inplace=True)
result = pd.concat([normalised_data, y], axis=1)
result.shape
result.head()
df_train_new = result.iloc[:len(df_train),:] 
df_test_new = result.iloc[len(df_train):,:]
print(df_train_new.shape)
print(df_test_new.shape)
df_train_new.to_csv("6.normalized_train.csv", index=False)
df_test_new.to_csv("6.normalized_test.csv", index=False)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.13708399366085577, 'fraction_numerical': 0.006339144215530904, 'mean_word_length': 9.268292682926829, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '441626', 'license': 'MIT', 'n_tokens_mistral': 495, 'n_tokens_neox': 489, 'n_words': 67, 'path': '6. Normalization.ipynb', 'repo_name': 'vhiefa/People-Analytics-BRI-Challenge-EDA', 'size': '1262'}