Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Point-to-Polygon in Stata


From   Nick Cox <[email protected]>
To   "[email protected]" <[email protected]>
Subject   Re: st: Point-to-Polygon in Stata
Date   Tue, 16 Apr 2013 15:40:07 +0100

Non sequitur to your bottom line. Point-in-polygon code available for
free is easy to find. I found a free R package in less than a minute.
So you don't need to use a proprietary GIS. (I am shocked to learn
that a substantial U.S. university doesn't have a licence, but there
you go.)

I'll match you in preference to do things in Stata wherever possible,
but you already have an answer. Maurizio Pisati wrote a Mata function
which you would need to integrate into Stata code. If that's too
difficult, as it could well be if you have no real experience of
programming in Stata, I think you'll need to go outside Stata.

Nick
[email protected]

On 16 April 2013 15:21, Jeremy Wells <[email protected]> wrote:

> I have been using Dr. Pisati's fun spmap program, but I have run into
> a bit of a snag.
>
> I have a dataset of about 76,000 observations, coded by latitude/longitude,
> in one country. I also have the coordinate file for the country produced by
> shp2dta that includes the country's provinces. I would like to add a variable
> to the dataset that codes each observation with the region from the coordinate
> file, which is essentially a point-to-polygon operation.
>
> I have tried to find a way to doing this, including this (http://www.stata.com/statalist/archive/2008-10/msg00817.html)
> from Dr. Pisati, but I am not at all sure how to apply the code. (Plus,
> this was written five years ago, so surely there is something that has
> been developed and is a little easier to use!)
>
> Thanks for your consideration! Please limit the responses to Stata-only
> applications as I do not have access to expensive GIS software.
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index