[GRASS-dev] pysal file I/O

I am trying to write a script using pysal for point pattern analysis. From their manual, “PySAL contains a new file input-output API that should be used for all file IO operations” (pysal.readthedocs.io/en/latest/users/tutorials/fileio.html).

Does anybody know or has suggestions how to get a grass vector layer ready for further analysis with pysal within a grass script using this I/O api?

Paulo

pvanbosgeo wrote

I am trying to write a script using pysal for point pattern analysis. From
their manual, "PySAL contains a new file input-output API that should be
used for all file IO operations" (
pysal.readthedocs.io/en/latest/users/tutorials/fileio.html).

Does anybody know or has suggestions how to get a grass vector layer ready
for further analysis with pysal within a grass script using this I/O api?

Paulo

_______________________________________________
grass-dev mailing list

grass-dev@.osgeo

http://lists.osgeo.org/mailman/listinfo/grass-dev

In mentioned doc, there are e.g. Shapefile or csv listed as exchange format?

AFAIU the I/O api is able to read these listed exchange formats.

-----
best regards
Helmut
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/pysal-file-I-O-tp5301192p5301198.html
Sent from the Grass - Dev mailing list archive at Nabble.com.

On 23 December 2016 3:26:58 pm Helmut Kudrnovsky hellik@web.de wrote:

pvanbosgeo wrote

I am trying to write a script using pysal for point pattern analysis. From
their manual, “PySAL contains a new file input-output API that should be
used for all file IO operations” (
pysal.readthedocs.io/en/latest/users/tutorials/fileio.html).

Does anybody know or has suggestions how to get a grass vector layer ready
for further analysis with pysal within a grass script using this I/O api?

Paulo


grass-dev mailing list

grass-dev@.osgeo

http://lists.osgeo.org/mailman/listinfo/grass-dev

In mentioned doc, there are e.g. Shapefile or csv listed as exchange format?

AFAIU the I/O api is able to read these listed exchange formats.

Yes, but I was wondering if it would be possible without first converting / exporting to another format.


best regards
Helmut

View this message in context: http://osgeo-org.1560.x6.nabble.com/pysal-file-I-O-tp5301192p5301198.html
Sent from the Grass - Dev mailing list archive at Nabble.com.


grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Depends what you are planing to do in more detail. But maybe the pygrass Vector or VectorTopo module could be of help...
https://grass.osgeo.org/grass70/manuals/libpython/pygrass_vector.html

Cheers
Stefan
________________________________________
Von: grass-dev [grass-dev-bounces@lists.osgeo.org] im Auftrag von Paulo van Breugel [p.vanbreugel@gmail.com]
Gesendet: Freitag, 23. Dezember 2016 22:34
An: Helmut Kudrnovsky; grass-dev@lists.osgeo.org
Betreff: Re: [GRASS-dev] pysal file I/O

On 23 December 2016 3:26:58 pm Helmut Kudrnovsky <hellik@web.de> wrote:

pvanbosgeo wrote

I am trying to write a script using pysal for point pattern analysis. From
their manual, "PySAL contains a new file input-output API that should be
used for all file IO operations" (
pysal.readthedocs.io/en/latest/users/tutorials/fileio.html).

Does anybody know or has suggestions how to get a grass vector layer ready
for further analysis with pysal within a grass script using this I/O api?

Paulo

_______________________________________________
grass-dev mailing list

grass-dev@.osgeo

http://lists.osgeo.org/mailman/listinfo/grass-dev

In mentioned doc, there are e.g. Shapefile or csv listed as exchange format?

AFAIU the I/O api is able to read these listed exchange formats.

Yes, but I was wondering if it would be possible without first converting / exporting to another format.

-----
best regards
Helmut
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/pysal-file-I-O-tp5301192p5301198.html
Sent from the Grass - Dev mailing list archive at Nabble.com<http://Nabble.com>.
_______________________________________________
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

On 23-12-16 23:49, Blumentrath, Stefan wrote:

Depends what you are planing to do in more detail. But maybe the pygrass Vector or VectorTopo module could be of help...
https://grass.osgeo.org/grass70/manuals/libpython/pygrass_vector.html

I am looking to use the Moran I and related statistics available in pysal in a grass script to look at point patterns, and possibly write a small addon for it (there used to be an grass addon to compute moran I, would be nice to have it again). Pysal expects as import a shapefile, csv or a few other formats. So I can export a grass vector layer to e.g., shapefile, and read that in Pysal and run my analysis. However, I thought perhaps there is a more direct way to write a grass vector layer to pysal format that people know of. If not, I'll use the grass-shapefile-pysal route.

Cheers
Stefan
________________________________________
Von: grass-dev [grass-dev-bounces@lists.osgeo.org] im Auftrag von Paulo van Breugel [p.vanbreugel@gmail.com]
Gesendet: Freitag, 23. Dezember 2016 22:34
An: Helmut Kudrnovsky; grass-dev@lists.osgeo.org
Betreff: Re: [GRASS-dev] pysal file I/O

On 23 December 2016 3:26:58 pm Helmut Kudrnovsky <hellik@web.de> wrote:

pvanbosgeo wrote

I am trying to write a script using pysal for point pattern analysis. From
their manual, "PySAL contains a new file input-output API that should be
used for all file IO operations" (
pysal.readthedocs.io/en/latest/users/tutorials/fileio.html).

Does anybody know or has suggestions how to get a grass vector layer ready
for further analysis with pysal within a grass script using this I/O api?

Paulo

_______________________________________________
grass-dev mailing list
grass-dev@.osgeo
http://lists.osgeo.org/mailman/listinfo/grass-dev

In mentioned doc, there are e.g. Shapefile or csv listed as exchange format?

AFAIU the I/O api is able to read these listed exchange formats.

Yes, but I was wondering if it would be possible without first converting / exporting to another format.

-----
best regards
Helmut
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/pysal-file-I-O-tp5301192p5301198.html
Sent from the Grass - Dev mailing list archive at Nabble.com<http://Nabble.com>.
_______________________________________________
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

However, I
thought perhaps there is a more direct way to write a grass vector >layer
to pysal format that people know of. If not, I'll use the
grass-shapefile-pysal route.

no idea if pysal is able to read from pipe, if it's about point maybe it's
possible to feed the pipe by some v.report/v.db.select/pygrass output?

-----
best regards
Helmut
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/pysal-file-I-O-tp5301192p5301268.html
Sent from the Grass - Dev mailing list archive at Nabble.com.

On Sat, Dec 24, 2016 at 3:17 PM, Helmut Kudrnovsky <hellik@web.de> wrote:

>However, I
>thought perhaps there is a more direct way to write a grass vector >layer
>to pysal format that people know of. If not, I'll use the
>grass-shapefile-pysal route.

no idea if pysal is able to read from pipe, if it's about point maybe it's
possible to feed the pipe by some v.report/v.db.select/pygrass output?

I'll look into it, thanks

-----
best regards
Helmut
--
View this message in context: http://osgeo-org.1560.x6.
nabble.com/pysal-file-I-O-tp5301192p5301268.html
Sent from the Grass - Dev mailing list archive at Nabble.com.
_______________________________________________
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev