Skip to main content

Hi, I have a dataset of point like this

UserID Long Lat Total_count

001 1 1 13

001 2 2 1

002 3 3 20

002 4 4 2

003 5 5 30

003 6 6 5

.....

How can I pick only the user with maximum total count and keep the long/lat attributes in the output?

If you sort on UserID and Total_count and then use a Sampler, grouped by UserID to sample the first feature you end up with

UserID Long Lat Total_count
001 1 1 13 002 3 3 20 003 5 5 30

That's what you want, right?

0684Q00000ArKrTQAV.png


If you sort on UserID and Total_count and then use a Sampler, grouped by UserID to sample the first feature you end up with

UserID Long Lat Total_count
001 1 1 13 002 3 3 20 003 5 5 30

That's what you want, right?

0684Q00000ArKrTQAV.png

Nice and simple, @redgeographics. I was thinking way to complicated.

 


Nice and simple, @redgeographics. I was thinking way to complicated.

 

>takes bow]

 

 


Thanks @redgeographics. Exactly what I want


If you sort on UserID and Total_count and then use a Sampler, grouped by UserID to sample the first feature you end up with

UserID Long Lat Total_count
001 1 1 13 002 3 3 20 003 5 5 30

That's what you want, right?

0684Q00000ArKrTQAV.png

Hi @redgeographics

 

 

 

how about if I want to pick out the userID with 1 row only. For example

 

USerID        Long           Lat              Count

 

001                1                1                    20

 

001                2                2                    1

 

002                3                 3                   5

 

003                4                  4                   20

 

003                5                   5                   6

 

004                6                    6                  9

 

I need to pick out the userID 002 and 004

 


Reply