该 Nominal to Numeric operator将创建名称将从输入属性的值派生的新属性。这发生在 dummy encoding 用于 coding type 参数。如果测试数据与训练数据相比包含不同的值,则结果属性将不同。
Nominal to Numeric
dummy encoding
coding type
要确认这是问题,请在之后设置断点 Nominal to Numeric 运算符并检查每个示例集的属性。
您可以通过将参数设置为更改操作员的工作方式 unique integers 但这可能不适合您要解决的问题。
unique integers
解决它的一种可能方法是组合两个数据集,然后再次拆分它们。这具有为每个标称属性创建允许级别的效果,即使数据可能没有该值的示例。然后可以使用每个拆分 Nominal to Numeric 运算符,它应该创建所有必需的属性。