Datasets:
Upload fertility.py
Browse files- fertility.py +1 -1
fertility.py
CHANGED
@@ -158,7 +158,7 @@ class Fertility(datasets.GeneratorBasedBuilder):
|
|
158 |
for feature in _ENCODING_DICS:
|
159 |
encoding_function = partial(self.encode, feature)
|
160 |
data.loc[:, feature] = data[feature].apply(encoding_function)
|
161 |
-
data[:, "age_at_time_of_sampling"] = data["age_at_time_of_sampling"].apply(lambda x: 18 + x * 18)
|
162 |
|
163 |
data = data[list(features_types_per_config[config].keys())]
|
164 |
|
|
|
158 |
for feature in _ENCODING_DICS:
|
159 |
encoding_function = partial(self.encode, feature)
|
160 |
data.loc[:, feature] = data[feature].apply(encoding_function)
|
161 |
+
data.loc[:, "age_at_time_of_sampling"] = data["age_at_time_of_sampling"].apply(lambda x: 18 + x * 18)
|
162 |
|
163 |
data = data[list(features_types_per_config[config].keys())]
|
164 |
|