{
  "id": 53532,
  "title": "XGBoost Factors in R??",
  "url": "/competitions/talkingdata-adtracking-fraud-detection/discussion/53532",
  "author_name": "AmirH",
  "post_date": "2018-04-01T05:07:24.339000",
  "votes": 1,
  "comment_count": 0,
  "views": 0,
  "content": "<p>Hi!\nQuestion:\nIn the cast for example the feature \"device\", the value is numeric, but it is actually categorical.\nI haven't seen in any of the R XGBoost kernels anyone using \"as.factor\" on the columns before training.</p>\n\n<p>What is the reason for that?\nShouldn't I use \"as.factor\" on all categorical columns before running the XGBoost?</p>\n\n<p>Thanks!</p>",
  "messages": [
    {
      "id": 307214,
      "postDate": "2018-04-01T05:07:24.340Z",
      "content": "<p>Hi!\nQuestion:\nIn the cast for example the feature \"device\", the value is numeric, but it is actually categorical.\nI haven't seen in any of the R XGBoost kernels anyone using \"as.factor\" on the columns before training.</p>\n\n<p>What is the reason for that?\nShouldn't I use \"as.factor\" on all categorical columns before running the XGBoost?</p>\n\n<p>Thanks!</p>",
      "rawMarkdown": "Hi!\nQuestion:\nIn the cast for example the feature \"device\", the value is numeric, but it is actually categorical.\nI haven't seen in any of the R XGBoost kernels anyone using \"as.factor\" on the columns before training.\n\nWhat is the reason for that?\nShouldn't I use \"as.factor\" on all categorical columns before running the XGBoost?\n\nThanks!",
      "votes": 1
    }
  ],
  "comments": [],
  "raw_markdown_by_id": {
    "307214": "Hi!\nQuestion:\nIn the cast for example the feature \"device\", the value is numeric, but it is actually categorical.\nI haven't seen in any of the R XGBoost kernels anyone using \"as.factor\" on the columns before training.\n\nWhat is the reason for that?\nShouldn't I use \"as.factor\" on all categorical columns before running the XGBoost?\n\nThanks!"
  }
}