arff unparseable date

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

arff unparseable date

ivan
Hello,

Below is the 23 first line of my data, before it was working fine with my
date, but i added some new NUMERIC attribute  and now It s say my date
format is bad... and I don't understand why? It seem fine for me.

Error :
error unparseable date : 2019-07-11-14:02:10, read
Token[2019-07-11-14:02:10], line 14
FILE:
@RELATION request

@ATTRIBUTE category string
@ATTRIBUTE field string
@ATTRIBUTE timestamp date "yyyy-MM-dd-hh:mm:ss"
@ATTRIBUTE dayOfWeek NUMERIC
@ATTRIBUTE dayOfMonth NUMERIC
@ATTRIBUTE weekOfYear NUMERIC
@ATTRIBUTE dayFreq NUMERIC
@ATTRIBUTE 30LastFreq NUMERIC
@ATTRIBUTE calledLastDay NUMERIC

@DATA
56,"someString",2019-07-11-14:02:10,5,11,28,5,22,0  // <- line 14
56,"someString2",2019-07-11-14:02:10,5,11,28,5,22,0
56,"someString3",2019-07-11-14:02:10,5,11,28,5,90,1
56,"someString",2019-07-11-14:02:10,5,11,28,5,464,1
45,"someString",2019-07-15-10:32:51,2,15,29,2,456,1
45,"someString",2019-07-15-10:32:51,2,15,29,2,216,1
45,"someString",2019-07-15-10:32:51,2,15,29,1,90,1
53,"someString",2019-07-15-10:41:34,2,15,29,4,711,1
59,"someString",2019-07-15-10:41:34,2,15,29,3,1290,1
53,"someString",2019-07-15-10:41:34,2,15,29,4,592,1



--
Sent from: https://weka.8497.n7.nabble.com/
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to: To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit
https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: arff unparseable date

Peter Reutemann-3
On November 23, 2019 5:59:40 AM GMT+13:00, ivan <[hidden email]> wrote:

>Hello,
>
>Below is the 23 first line of my data, before it was working fine with
>my
>date, but i added some new NUMERIC attribute  and now It s say my date
>format is bad... and I don't understand why? It seem fine for me.
>
>Error :
>error unparseable date : 2019-07-11-14:02:10, read
>Token[2019-07-11-14:02:10], line 14
>FILE:
>@RELATION request
>
>@ATTRIBUTE category string
>@ATTRIBUTE field string
>@ATTRIBUTE timestamp date "yyyy-MM-dd-hh:mm:ss"
>@ATTRIBUTE dayOfWeek NUMERIC
>@ATTRIBUTE dayOfMonth NUMERIC
>@ATTRIBUTE weekOfYear NUMERIC
>@ATTRIBUTE dayFreq NUMERIC
>@ATTRIBUTE 30LastFreq NUMERIC
>@ATTRIBUTE calledLastDay NUMERIC
>
>@DATA
>56,"someString",2019-07-11-14:02:10,5,11,28,5,22,0  // <- line 14
>56,"someString2",2019-07-11-14:02:10,5,11,28,5,22,0
>56,"someString3",2019-07-11-14:02:10,5,11,28,5,90,1
>56,"someString",2019-07-11-14:02:10,5,11,28,5,464,1
>45,"someString",2019-07-15-10:32:51,2,15,29,2,456,1
>45,"someString",2019-07-15-10:32:51,2,15,29,2,216,1
>45,"someString",2019-07-15-10:32:51,2,15,29,1,90,1
>53,"someString",2019-07-15-10:41:34,2,15,29,4,711,1
>59,"someString",2019-07-15-10:41:34,2,15,29,3,1290,1
>53,"someString",2019-07-15-10:41:34,2,15,29,4,592,1
>
>
>
>--
>Sent from: https://weka.8497.n7.nabble.com/
>_______________________________________________
>Wekalist mailing list -- [hidden email]
>Send posts to: To unsubscribe send an email to
>[hidden email]
>To subscribe, unsubscribe, etc., visit
>https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
>List etiquette:
>http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

You're using the wrong format string, "hh" is 12 hour format:

https://docs.oracle.com/javase/7/docs/api/java/text/SimpleDateFormat.html

Cheers, Peter
--
Peter Reutemann
Dept. of Computer Science
University of Waikato, NZ
+64 (7) 858-5174
http://www.cms.waikato.ac.nz/~fracpete/
http://www.data-mining.co.nz/
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to: To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit
https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: arff unparseable date

ivan
Oh you are right, thank you for your reply



--
Sent from: https://weka.8497.n7.nabble.com/
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to: To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit
https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html