Weka not recognizing attribute in "date" format

Asked

Viewed 289 times

2

I have a treatment and testing suite that I created with a Java program.

In the headline, it’s like this:

*@attribute data date "yyyy-MM-dd"*

And among other attributes.

An example of a data line is:

*@data

"2014-01-02",11.27,11.44,11.03,11.18,11.07,11.07,11.12,9419,2003400,2240946600,1*

But the strange thing is that when I open the file .arff in Weka, the date is classified bizarrely, the generated graph of the attribute data between intervals nothing to do with 138862800000 and 1419904800000.

As a result, I cannot classify this set correctly, or it plays everything as class 1 or class 2.

How do I arrange the date?

  • Hello Thiago, have you had any success? managed to solve the problem? I’m starting my studies with Weka.

2 answers

1

It is in the format of milesseconds, if you click Edit you will probably see the correct date formatting, basically it is a float type, and this is because WEKA works with numerical values. To get around this, you should perform a data transformation through the Changedateformat filter (filters->unsupervised->attribute->ChangeDateFormat), choose the index of the attribute(attributeIndex) and the format (dateFormat), then click Ok and Apply. To finish apply the filter NunericToNiminal to convert the data to the nominal type.

0

All right? Dude, Weka is going to show the date timestamp on that home screen. Try running something over your dataset, and see how it behaves. For example: Run a forecasting, see that it will display the dates normally, as in the specified ARFF file. If it still doesn’t work, update the question with the function you are trying to use.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.