The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here
[SOLVED] Generating Attributes for a specific date range
Analyticaltim
Member Posts: 15 Contributor II
Dear Rapi-i Community,
I am working on a project where I need to generate an attribute for a specific date range. For example: Dates from 4/1/13 till 4/7/13 get a "week 1" attribute. Etc.
I was thinking about using the 'Generate Attribute' operation with a 'before date' command and an 'after date' command. But this seems very clunky and not replicateable over many iterations.
Do you have any advice to offer? ::)
Thank you very much.
Tim
I am working on a project where I need to generate an attribute for a specific date range. For example: Dates from 4/1/13 till 4/7/13 get a "week 1" attribute. Etc.
I was thinking about using the 'Generate Attribute' operation with a 'before date' command and an 'after date' command. But this seems very clunky and not replicateable over many iterations.
Do you have any advice to offer? ::)
Thank you very much.
Tim
0
Answers
Tim
sorry, I know this topic is marked "solved", but there's something I don't understand.
I tried this procedure and it works for "29/12/2012", but for dates "30/12/2012" and "31/12/2012" I get week 1, not 52.
Could somebody help me out?
It's got to do with where the week numbering system starts. Some systems start at "Week 0" and some start at "Week 1". It also depends on the day of the week that the week starts on (Sunday or Monday)...
It can get pretty confusing especially when you're working with different software....Excel, SQL ect ect...
Also, I'm not sure what RapidMiner regards as the first week of the year...Is week 53 of the old year also week 0 or 1 of the new year?
I work around for a lot of this stuff is using the year concatenated to the week "yyyyww"