How to order statistical data (spatial panel)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

How to order statistical data (spatial panel)

Rolando Valdez
Hello all,

I will to perform a spatial panel data, I have statistical data of 2000+
territories in 5 years ordered as typical simple panel data (Each
territoriy has a unique geocode).

In the other hand I have a shapefile with those 2000+ territories, but,
when I've opened the dbf file, the order of units seems to have not order
criteria. These ones have geocode too (same than statistical).

The question is, how should I order my data to garantee a right matching
between statistical and geographical data?

--
Rol~

        [[alternative HTML version deleted]]

_______________________________________________
R-sig-Geo mailing list
[hidden email]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo
Reply | Threaded
Open this post in threaded view
|

Re: How to order statistical data (spatial panel)

Kent Johnson
>
>
> Date: Fri, 15 Sep 2017 11:45:59 -0500
> From: Rolando Valdez <[hidden email]>
> To: [hidden email]
> Subject: [R-sig-Geo] How to order statistical data (spatial panel)
> Message-ID:
>         <CAFvJtoHnwOqtd8oWj_P3sfLRAX-uCHgGhDTi8Hr8TgDJkT++-w@mail.
> gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> Hello all,
>
> I will to perform a spatial panel data, I have statistical data of 2000+
> territories in 5 years ordered as typical simple panel data (Each
> territoriy has a unique geocode).
>
> In the other hand I have a shapefile with those 2000+ territories, but,
> when I've opened the dbf file, the order of units seems to have not order
> criteria. These ones have geocode too (same than statistical).
>
> The question is, how should I order my data to garantee a right matching
> between statistical and geographical data?
>

I would think you would do a merge or join of the spatial data with your
statistical data using geocode as the key, rather than a cbind or similar
operation that depends on order. See ?sp::merge or ?sf::merge.sf.

Kent

        [[alternative HTML version deleted]]

_______________________________________________
R-sig-Geo mailing list
[hidden email]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo
Reply | Threaded
Open this post in threaded view
|

Re: How to order statistical data (spatial panel)

Rolando Valdez
In reply to this post by Rolando Valdez
Thank you for your answer, and sorry for the late. First I needed to solve the problem with the unbalanced data. Now I did, but I still don’t know how to merge the data.


Rolando Valdez

From: César Soares
Sent: Saturday, September 16, 2017 7:12 AM
To: Rolando Valdez
Subject: Re: [R-sig-Geo] How to order statistical data (spatial panel)

hey, try the package CARBayesST in R, you should get over it with this.

https://cran.r-project.org/web/packages/CARBayesST/vignettes/CARBayesST.pdf

Hope it helps.

César

2017-09-15 13:45 GMT-03:00 Rolando Valdez <[hidden email]>:
Hello all,

I will to perform a spatial panel data, I have statistical data of 2000+
territories in 5 years ordered as typical simple panel data (Each
territoriy has a unique geocode).

In the other hand I have a shapefile with those 2000+ territories, but,
when I've opened the dbf file, the order of units seems to have not order
criteria. These ones have geocode too (same than statistical).

The question is, how should I order my data to garantee a right matching
between statistical and geographical data?

--
Rol~

        [[alternative HTML version deleted]]

_______________________________________________
R-sig-Geo mailing list
[hidden email]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo



        [[alternative HTML version deleted]]

_______________________________________________
R-sig-Geo mailing list
[hidden email]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo
Reply | Threaded
Open this post in threaded view
|

Re: How to order statistical data (spatial panel)

Rolando Valdez
In reply to this post by Kent Johnson
Yes, your right, I want to merge the statistical data with the spatial one. I’ll read about your suggestion,

Thank you.

Rolando Valdez

From: Kent Johnson
Sent: Saturday, September 16, 2017 12:02 PM
To: [hidden email]
Subject: Re: [R-sig-Geo] How to order statistical data (spatial panel)

>
>
> Date: Fri, 15 Sep 2017 11:45:59 -0500
> From: Rolando Valdez <[hidden email]>
> To: [hidden email]
> Subject: [R-sig-Geo] How to order statistical data (spatial panel)
> Message-ID:
>         <CAFvJtoHnwOqtd8oWj_P3sfLRAX-uCHgGhDTi8Hr8TgDJkT++-w@mail.
> gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> Hello all,
>
> I will to perform a spatial panel data, I have statistical data of 2000+
> territories in 5 years ordered as typical simple panel data (Each
> territoriy has a unique geocode).
>
> In the other hand I have a shapefile with those 2000+ territories, but,
> when I've opened the dbf file, the order of units seems to have not order
> criteria. These ones have geocode too (same than statistical).
>
> The question is, how should I order my data to garantee a right matching
> between statistical and geographical data?
>

I would think you would do a merge or join of the spatial data with your
statistical data using geocode as the key, rather than a cbind or similar
operation that depends on order. See ?sp::merge or ?sf::merge.sf.

Kent

        [[alternative HTML version deleted]]

_______________________________________________
R-sig-Geo mailing list
[hidden email]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo


        [[alternative HTML version deleted]]

_______________________________________________
R-sig-Geo mailing list
[hidden email]
https://stat.ethz.ch/mailman/listinfo/r-sig-geo