I am trying to extract the features using the get_feature_names function of the OneHotEncoder object of scikit learn but its is throwing me an error saying "'OneHotEncoder' object has no attribute 'get_feature_names'".
Below is the code snippet
# Creating the object instance for label encoder
encoder = OneHotEncoder(sparse=False)
onehot_encoded = encoder.fit_transform(df[data_column_category])
onehot_encoded_frame = pd.DataFrame(onehot_encoded,columns = encoder.get_feature_names(data_column_category))