Displaying 1 result from an estimated 1 matches for "lat_lon".
Did you mean:
athlon
2024 Dec 02
1
Identify first row of each ID within a data frame, create a variable first =1 for the first row and first=0 of all other rows
.... To accomplish this, I need to
>
> 1) Group data from each of the 500 geographic areas together
>
> 2) Within each geographic area order the observations by day and time
> 1) and 2) are easily accomplished using the R order function,
> mydata<-mydata[order(mydata$lat_lon,mydata$Time),]
>
> or SAS proc sort:
> proc sort data=mydata;
> by lat_lon daytime; /* lat long is a string giving latitude and longitude */
> run;
>
> 3) For each geographic area determine the records that mark the start and stop of each of the fou...