I am using xgboost recently and here are my questions

(1) When I applied xgboost both on R and Python, I found that there is a parameter called "n_round" in R, but I can't find this parameter in Python xgbRegressor(). What this n_round means? Does it equals to the n_estimators we set up?

(2)By this website http://xgboost.readthedocs.io/en/latest/python/python_intro.html I found that it used num_round, which seem to be n_round in R. import xbgoost as xgb xgb.train(num_round = 2)

But when in xgbClassifier, why there is no num_round parameter ? from xgboost import xgbClassifier model = xgbClassifier() model.fit(train) Thanks


1 Answer 1


I asked exactly the same question for R's implementation of xgboost. n_rounds is the equivalence of n_estimators in python.


The author of the package needs to fix this confusing discrepancy.

  • $\begingroup$ Thanks for your reply! But there is a parameter in R, called "num_parallel_tree " Do you know what does that means? for example, if we set n_rounds = 100, num_paralle_tree = 1. How many trees will we have in final result? $\endgroup$
    – jimmy15923
    Mar 9, 2017 at 6:24
  • $\begingroup$ @jimmy15923 The doc says it's experimental for comparing with RF. I'd leave it at 1. $\endgroup$
    – horaceT
    Mar 9, 2017 at 22:26

Not the answer you're looking for? Browse other questions tagged or ask your own question.