Dear Statalisters,
I am trying to convert coordinates in meters to xy latitude and longitude in Stata. I use Robert Picard's [geoinpoly] package to generate the xy coordinates so I can merge them with the shapefile.
The coordinates look like this:
_ID _X _Y
1 722289.86 1194827.3
2 724874.6 1194249.9
3 713779.37 1193967.1
4 719852.11 1195935.7
When I run the command:
geoinpoly _Y _X using "ttcoord.dta"
I get the error code 198:
latitude _Y must be between -90 and 90
r(198);
Even if I try using the option noprojection, I still get the same error.
Any advice would be greatly appreciated.
Thank you
Erik
Related Posts with Convert xy coordinate in meters to degrees in Stata
Estimating Total Factor Productivity for panel data in StataHi, I am a new STATA 15 user. I am doing my assignment on estimating the Total Factor Productivity f…
Forloops in panel data - am I indexing incorrectly?I am trying to use a loop in stata to achieve the following: My example data is below, but a brief …
Help in generating a variable based on certain conditionDear All I want to create a disability identifier based on the following criteria those who respon…
Forloops in panel data - am I indexing incorrectly and using 'if' statements correctly?I am trying to use a loop in stata to achieve the following: My example data is below, but a brief …
missing value for string type and missing value for numeric typeHi , I'm now trying to replace the two conditions. If the variable is the string, replace var ==" OR…
Subscribe to:
Post Comments (Atom)
0 Response to Convert xy coordinate in meters to degrees in Stata
Post a Comment