rknimmakayala
rknimmakayala

Reputation: 21

h2o target encoding feature

Just trying to understand the target encoding map and apply features in R html doc, mapping <- h2o.target_encode_create(data = train, x = list(c("job"), c("job", "marital")), y = "age")

In the above mapping, why is job given separately as part of the list? Is it some sort of interaction variables, why did we miss marital as a separate feature? can we give n number of categorical variables as part of the list or creating separate mapping for each categorical variable is recommended?

Upvotes: 0

Views: 440

Answers (1)

IRTFM
IRTFM

Reputation: 263411

I did a search on that function name and immediately found a document that explained the function of a list item in the arguments to the x parameter:

x
A list containing the names or indices of the variables to encode. A target encoding map will be created for each element in the list. Items in the list can be multiple columns. For example, if x = list(c("A"), c("B", "C")), then there will be one mapping frame for A and one mapping frame for B & C (in this case, we group by two columns).

Upvotes: 2

Related Questions