Target Encode
Encode a categorical column with the average value of a target column for the corresponding value of the categorical column.
Name | Type | Description | Is Optional |
---|---|---|---|
column | column | Column name to target encode | |
target | column | Numeric target column to use to create averages | |
ds = rasgo.get.dataset(id)
ds2 = ds.target_encode(column='WEATHER_DESCRIPTION', target='DAILY_HIGH_TEMP')
ds2.preview()
Last modified 7mo ago