Survey banner
The Dataiku Community is moving to a new home! Some short term disruption starting next week: LEARN MORE

How to create a sequence number

abalo006
Level 3
How to create a sequence number

I have a table with four 3 columns, date, color and time. Im trying to create some kind of sequence field that takes into consideration the first time the color was seen on a specific day.

 

Ex. green was seen on 4/24 at 15:00 and again on 4/24 at 15:30 and again at 15:45, because 3 is the earliest I want that sequence number to be 1, then 15:30 as 2 and 15:45 as 3, essentially raking then dependent on which one was seen first on a specific day.

 

Ex. blue was seen on the 25th at 15:00 and again at 15:55 so I want that first instance to have a sequence number of 1 and the second to have a sequence number of 2.

 

Ive attached a sample of my desired output below.

Capture.PNG

 

it that possible? and if so, how would I accomplish that within Dataiku?


Operating system used: windows

0 Kudos
1 Reply
Turribeach

Thank you for uploading dummy data, makes it much easier to respond. Use a Window recipe. 

 

Screenshot 2024-04-26 at 18.40.10.pngScreenshot 2024-04-26 at 18.40.15.pngScreenshot 2024-04-26 at 18.39.58.png

0 Kudos

Labels

?
Labels (2)
A banner prompting to get Dataiku