Datasets:
Tasks:
Tabular Classification
Languages:
English
Upload p53.py
Browse files
p53.py
CHANGED
@@ -87,12 +87,8 @@ class P53(datasets.GeneratorBasedBuilder):
|
|
87 |
data.loc[:, feature] = data[feature].apply(encoding_function)
|
88 |
|
89 |
for feature in data.columns:
|
90 |
-
print(f"on feature {feature}\n\n\n")
|
91 |
if feature == "class":
|
92 |
break
|
93 |
-
|
94 |
-
print(data[data[feature] == "?"].shape)
|
95 |
-
print(data[data[feature] != "?"].astype(float).mean())
|
96 |
data.loc[data[feature] == "?", feature] = data[data[feature] != "?"].astype(float).mean()
|
97 |
|
98 |
return data[list(features_types_per_config[self.config.name].keys())]
|
|
|
87 |
data.loc[:, feature] = data[feature].apply(encoding_function)
|
88 |
|
89 |
for feature in data.columns:
|
|
|
90 |
if feature == "class":
|
91 |
break
|
|
|
|
|
|
|
92 |
data.loc[data[feature] == "?", feature] = data[data[feature] != "?"].astype(float).mean()
|
93 |
|
94 |
return data[list(features_types_per_config[self.config.name].keys())]
|