Hi everyone,
I am working with trip data and i'd like to be able to find wich fraction of my trips goes from location 1 to 2, 1 to 3, ... , 6 to 1, ... , 6 to 5. (If i suppose i have n=6 locations).
I have coordinates variables, start of trip coordinates and end of trips coordinates.
I tried to generate variables : startn1 (you start at location 1), startn2, and so on. The thing is i'm not able to delimit my area when following streets.
(see for exemple Lagos, 2003).
Is there a way with stata and coordinates to tell that all these coordinates goes to location 1, 2 and so on until location 6.
There's a way where i can just set boundaries using coordinates, but if i do that i am cutting the streets on the map since they are diagonals and coordinates are straight lines (sorry if not clear).
For exemple, i'd like to set limits for zone n=1 to ;
40.82; -73.96
40.7856;-73.9844 40.81;-73.93
40.77;-73.94
Imagine diagonals between these coordinates. I can't find a way to tell stata to use these limits.
If i use 40.77;-73.94 as lower bound for location n=1, it will also include areas below 40.7856;-73.9844 (wich belong to location n=2)
Thank you for clarification and sorry in advance if im not clear enough.
I am working with trip data and i'd like to be able to find wich fraction of my trips goes from location 1 to 2, 1 to 3, ... , 6 to 1, ... , 6 to 5. (If i suppose i have n=6 locations).
I have coordinates variables, start of trip coordinates and end of trips coordinates.
I tried to generate variables : startn1 (you start at location 1), startn2, and so on. The thing is i'm not able to delimit my area when following streets.
(see for exemple Lagos, 2003).
Is there a way with stata and coordinates to tell that all these coordinates goes to location 1, 2 and so on until location 6.
There's a way where i can just set boundaries using coordinates, but if i do that i am cutting the streets on the map since they are diagonals and coordinates are straight lines (sorry if not clear).
For exemple, i'd like to set limits for zone n=1 to ;
40.82; -73.96
40.7856;-73.9844 40.81;-73.93
40.77;-73.94
Imagine diagonals between these coordinates. I can't find a way to tell stata to use these limits.
If i use 40.77;-73.94 as lower bound for location n=1, it will also include areas below 40.7856;-73.9844 (wich belong to location n=2)
Thank you for clarification and sorry in advance if im not clear enough.