I'm using the scikit-learn package to run random forest (RandomForestRegressor) in python. A section of my code looks like this:
clf = RandomForestRegressor(n_estimators=100, oob_score=True)
clf.fit(y, x)
print clf.score(y, x)
print clf.oob_score
Execution of the code gave me two different numbers corresponding to the third and fourth lines (0.945098 and 0.596445, respectively). My understanding is that the first printed measure is called "score" and it is equivalent to R2 in linear regression and the second printed mearure is "OOB score" and it is related to the error rate. Am i correct? If so, can these two measures be used interchangably when evaluating the performance of random forest models? IE, can i simply stick with one of them when comparing models
Thanks!