| 6 | |
| 7 | ## Need to make sure we have CountEncoder available from the category_encoders library |
| 8 | class TestCategoryEncoders(unittest.TestCase): |
| 9 | def test_count_encoder(self): |
| 10 | encoder = CountEncoder(cols="data") |
| 11 | |
| 12 | data = pd.DataFrame([1, 2, 3, 1, 4, 5, 3, 1], columns=["data"]) |
| 13 | |
| 14 | encoded = encoder.fit_transform(data) |
| 15 | self.assertTrue((encoded.data == [3, 1, 2, 3, 1, 1, 2, 3]).all()) |
| 16 |
nothing calls this directly
no outgoing calls
no test coverage detected