Вопрос

I am working on a project with Weka and I have two different arff files as follows:

file1:

@attribute class {yes, no}    
@attribute a numeric    
@data    
{0 yes, 1 2}    
{0 yes}

file2:

@attribute class {yes, no}    
@attribute b numeric    
@attribute a numeric    
@data    
{0 yes, 1 2}    
{0 no, 1 1, 2 1}

Is there a way to create a new file by combining these two arff files as follows?

file3:

@attriute class{yes, no}    
@attribute a numeric    
@attribute b numeric    
@data
{0 yes, 1 2} ("copied" from file 1)    
{0 yes} ("copied" from file 1)    
{0 yes, **2** 2} ("copied" from file 2)    
{0 no, **2** 1, **1** 1} ("copied" from file 2)

Merging and does not work, since I have different attributes on every file.

Это было полезно?

Решение

This class offers the API to combine different datasets. The only requeriment is that the .arff files must have different relation names.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top