Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Convert to Weka date format

Tags:

datetime

weka

I have a csv file with some attributes. One is a date attribute with date in this form - yyyy-mm-dd hh:mm:ss . But Weka takes it as nominal not as date type. How to fix this? Please help me with this. (I use Weka Explorer)

like image 393
harsh Avatar asked Jun 25 '15 19:06

harsh


People also ask

What is ARFF file in Weka?

ARFF stands for Attribute-Relation File Format. It is an ASCII text file that describes a list of instances sharing a set of attributes. ARFF files were developed by the Machine Learning Project at the Department of Computer Science of The University of Waikato for use with the Weka machine learning software.

How many data type are provided by Weka?

Numeric (Integer and Real), String, Date, and Relational are the only four datatypes provided by WEKA.


2 Answers

A nice reference, you can get it here: https://waikato.github.io/weka-wiki/formats_and_processing/arff_stable/

It's a simple compilation of attributes from Weka files ...

Example for time:

@RELATION Timestamps

@ATTRIBUTE timestamp DATE "yyyy-MM-dd HH:mm:ss" 

@DATA 
"2001-04-03 12:12:12"
"2001-05-03 12:59:55"
like image 110
Daniel Leiva Avatar answered Sep 30 '22 21:09

Daniel Leiva


on opening the file select or check the invoke mark then a pop up will appear.on the date attribute put the index of the attribute which is a date and on dateFormat put the one similar from csv format then click ok the date will be detected as a date type now

like image 34
burhan rashid Avatar answered Sep 30 '22 21:09

burhan rashid