How to convert longitude and latitude in time series data from daily to weekly? I have time series data like this:




date
longitude
latitude




01/01/2010
-5.42766
107.5784


02/01/2010
-6.42728
104.5245


07/01/2010
-7.42702
105.5816


14/01/2010
-4.42728
99.57834


17/01/2010
-6.41523
103.5562


...
...
...


31/12/2013
-4.42728
99.57834




This is location data (longitude and latitude).
I want to change the data from daily to weekly, something like this:




week
longitude
latitude




week 1
...
...


week 2
...
...


week 3
...
...


week 4
...
...




how to transform the data? since calculating the mean of the data doesn't make sense because it is location data.
I don't know exactly whether it is useful for your case, but you can use last day of the week, so coordinates of the object at end of the week.
I copied your example data to a text file, read it with Pandas, and resampled data from daily to weekly by getting coordinates of the last day of each week.
df = pd.read_csv('untitled.txt', 
                 infer_datetime_format=True, 
                 parse_dates=['date'], dayfirst=True)
df.set_index('date', inplace=True)
df.resample('W').last()