简体   繁体   English

如何使用R / Rattle解释随机森林中的“级别”

[英]How to Interpret “Levels” in Random Forest using R/Rattle

I am brand new at using R/Rattle and am having difficulty understanding how to interpret the last line of this code output. 我是使用R / Rattle的新手,很难理解如何解释此代码输出的最后一行。 Here is the function call along with it's output: 这是函数调用及其输出:

> head(weatherRF$model$predicted, 10)
336 342 94 304 227 173 265 44 230 245
No No No No No No No No No No 
Levels: No Yes

This code is implementing a weather data set in which we are trying to get predictions for "RainTomorrow". 这段代码正在实现一个天气数据集,我们正在其中尝试获取“ RainTomorrow”的预测。 I understand that this function calls for the predictions for the first 10 observations of the data set. 我了解此功能要求对数据集的前10个观测值进行预测。 What I do NOT understand is what the last line ("Levels: No Yes") means in the output. 我不明白的是输出中最后一行(“ Levels:No Yes”)的含义。

It's called a factor variable. 这称为因子变量。

That is the list of permitted values of the factor, here the values No and Yes are permitted. 这是因子的允许值列表,此处允许使用No和Yes值。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM