Commit Graph
887 Commits
Author SHA1 Message Date
Joris Van den Bossche 8b5bcb4419 TST/DEP: remove support for pandas <0.19 (#708) 2018-04-29 13:58:38 +02:00
Joshua Wilson b0b01ec4f8 ENH: add support for plotting MultiPoints (#683) 2018-03-29 22:53:23 +02:00
Ramiro Gómez d3df5eb950 Adjust the scheme option docs to reflect the source code (#693)
I noticed some differences between the docs and the source code. By default scheme is ``None`` and ``equal_interval`` mustn't end with an s otherwise an exception is raised. I also changed the link because the current URL resolves to a 404 error.
2018-03-19 22:05:07 +01:00
mrahim 63b4279c6a Building a GeoDataFrame from DataFrame (#690) 2018-03-17 23:20:45 +01:00
Joris Van den Bossche ca35666242 BUG: fix GeoSeries construction from scalar on pandas master (#692) 2018-03-17 20:11:57 +01:00
Benjamin Root e98a289149 Explicitly set the dtype for geometry operations (#686)
Not doing so resulted in incorrect dtypes when the
result was empty since numpy could not automatically
determine the dtype. This then had the effect of
indexing dropping columns unexpectedly.
Closes #685
2018-03-17 16:20:38 +01:00
Joris Van den Bossche 8d39811b82 DOC: remove ambiguous 'minimum' in distance docstring (#674) 2018-03-14 21:23:20 -07:00
James McBride 891c5cd73c BLD: remove matplotlib master from 2.7 (#682)
Matplotlib master no longer supports python 2
2018-02-26 09:49:58 +01:00
James McBride 657483a3b3 Update CHANGELOG.md
Add substantive changes from the past few months
2018-02-25 14:10:39 -08:00
Joshua Wilson 97adf46803 ENH: accept bbox of geoseries for filtered read_file (#613)
* Fix for when read_file bbox crs does not match target file crs

* added tests for read_file with GeoSeries/GeoDataFrame boundary

* Group related tests in test_io

* Make adjustment to read_file bounding box doc
2018-02-25 14:00:14 -08:00
Christopher Ren a577b12486 ERR: Better error message for writing empty dataframe to file (#663) 2018-02-08 10:08:14 +01:00
Christopher Ren 2acd8b98f2 TST: test_geocode.py pytest conversion (#659) 2018-02-07 11:24:48 +01:00
James McBride a074f73e97 BUG/CLN: remove unused and broken test utility (#661)
The assert_seq_equal test was not used, and was written in such a
way that it would never fail.
2018-02-04 22:22:06 +01:00
James McBride 7b692fe8b5 BUG: Save z dimension in file writes (#652)
* BUG: Save z dimension in file writes

In so doing, add the has_z attribute to series. The check in determining
the geometry type is pretty simplistic. Given how fiona is thinking
about geometry types now (https://github.com/Toblerity/Fiona/issues/465)
I didn't see a clearly better way.

* Add test for a 3d polygon, too

* TST: Add has_z test

* TST: Mix 2D/3D polygons in file writes

Removed the pandas assert_frame_equal test because it will no longer
pass anywhere due to the 2D/3D handling, which doesn't look like
something there's any way around without changes to fiona (or possibly
GDAL?).
2018-01-30 21:59:04 -08:00
Joris Van den Bossche 36c8bcda34 BUG: read empty files correctly (#653) 2018-01-28 23:35:45 +01:00
Christopher Ren 6a72e7ef73 TST: Fixtures and test clean up for test_dissolve.py (#654) 2018-01-28 11:06:55 +01:00
Christopher Ren d98318948c TST: parametrized test_datasets.py tests (#646) 2018-01-27 10:07:22 +01:00
James McBride de7b657c22 Remove descartes from install requirements (#648)
* Remove descartes from install requirements

The descartes import in plotting is hidden, so it is not a hard
dependency, and should not be required for installation.

* Update install reqs in README.md
2018-01-26 19:59:56 -08:00
James McBride a3810f3170 Raise ValueError using to_file with bool column (#643)
* Raise ValueError using to_file with bool column

Fiona doesn't support writing to files with boolean type. There was some
discussion of converting to int and writing to file anyway, but at a
minimum seems useful to raise a clearer message about the problem.

* Improve warning with to_file on bool column
2018-01-24 19:44:37 -08:00
Joris Van den Bossche 8cad410ebd Update .gitignore (#628) 2018-01-19 20:08:45 +01:00
James McBride a9c9ebaa0f ENH: Set point markersize with column values (#633)
Can optionally set the size of points in a scatter plot of point
geometries to be specified by the value of a column in the frame. Note
that it does not perform any normalization at present, so very small or
very large values in the column specified lead to less than desirable
results. Also no checks on user, so if a user specifies a column with a
non numeric type, it does throw a slightly less than clear error.
2018-01-19 20:06:20 +01:00
Joris Van den Bossche 78e74f2689 DOC: fix readthedocs problems with conda (#641) 2018-01-16 18:27:59 +01:00
James McBride e36f827e33 DOC: Rely on conda for sphinx-gallery 2018-01-14 19:51:32 -08:00
James McBride de878fadf8 TST: Add test of naturalearth spatial join (#638)
Looking to test out issue raised in #637.
2018-01-12 21:05:54 -08:00
François Leblanc 7a7a3c8e1d Add link to JupyterHub's MyBinder, and fix example notebooks (#631)
* fixed nybb

* rearrange chloropleths example

* added badge to MyBinder

* extra formatting on README

* add extra info in chrolopleths.ipynb

* Update choropleths example
2017-12-22 09:25:52 -08:00
Joris Van den Bossche f38c6c1609 DOC/BLD: correct environment.yml file syntax 2017-11-24 09:29:41 +01:00
Filipe f01b951d4a CI: build env in one go (#617) 2017-11-21 13:37:43 +01:00
James McBride 80268d2ed1 DOC: Add minimal geocoding example for docs (#614)
Shows the location of borough centers accessed through Google geocoding
API, along with the boundaries in the shapefile included in geopandas.
2017-11-21 13:32:38 +01:00
Dmitri Lebedev 16ee64f7de PERF: writing mutliple records at once to increase speed in GeoPackage (#605) 2017-11-20 21:25:43 +01:00
Edward Betts 74fa1368a3 Correct spelling mistakes. (#615) 2017-11-20 15:56:48 +01:00
Chris Holdgraf 1da8f6279c DOC: add sphinx gallery for examples (#463) 2017-11-19 23:54:05 +01:00
James McBride 3e26d22b05 TST: Test inplace transform on geodataframe (#593)
Simple test effectively replicating the test on a not-inplace transform.
2017-11-19 14:43:24 -08:00
robochat 18160efc16 BUG: retain index names of input frames to sjoin (#545)
* BUG: sjoin modifies original frame (#525)

Original pandas table's index names are no
longer changed by sjoin() call. Includes
some unit-tests. Fixes issue #525

* New code to fix issue that is compatible with pandas 0.16.2 - 0.20.3

* applied suggested changes to test_sjoin.py
2017-10-22 13:59:27 -07:00
Dani Arribas-Bel 87e7541daf Fix error on plot empty GeoDataFrame (#571) 2017-10-16 23:34:29 +02:00
James McBride cc1a0f535b CLN: Remove try/except for old GEOS bug (#576)
Handling for a bug discussed in
https://github.com/Toblerity/Shapely/issues/47#issuecomment-18506767
seems no likely necessary, given the issue was fixed 4 years ago.
2017-10-16 21:38:41 +02:00
James McBride 714d9a8ea2 TST: Warning for sjoin CRS mismatch, and test (#577) 2017-10-16 21:35:33 +02:00
James McBride 2e9c72b22e Add asv benchmark for to_crs (#578) 2017-10-10 14:49:02 +02:00
James McBride 173e6e4265 COMPAT: Remove deprecated usage if ix (#579)
As of 0.20.0, pandas .ix is deprecated. This switches all such instances
to the label based .loc indexer. (In searching for usage, I also noticed
the CHANGELOG contained an error in describing the introduction of the
.cx indexer.)
2017-10-09 09:14:30 +02:00
James McBride 6daedd6b99 TST: Add test of overlay with non-integer index (#580)
All current overlay tests have indices for which loc/iloc give the same
result. Since ix will be deprecated, add a test to distinguish behavior
between the two.
2017-10-09 09:13:37 +02:00
Chris Holdgraf f053d654ba DOC: update installation instructions in README (#548) 2017-10-01 11:24:53 +02:00
James McBride 5fd7f2db42 TST: Set test gdf crs to silence crs warning (#567)
* TST: Set test gdf crs to silence crs warning

The symmetric difference test compared a frame with a crs to one
without. It didn't seem that this was intentional, so set the second
frame crs to the first so that the tests run without warnings.

Warning below:
geopandas/tests/test_geom_methods.py::TestGeomMethods::()::test_symmetric_difference_series
  /home/james/python/geopandas/geopandas/base.py:29: UserWarning: GeoSeries crs mismatch: {'init': 'epsg:4326', 'no_defs': True} and None
    other.crs))

geopandas/tests/test_geom_methods.py::TestGeomMethods::()::test_symmetric_difference_operator
  /home/james/python/geopandas/geopandas/base.py:29: UserWarning: GeoSeries crs mismatch: {'init': 'epsg:4326', 'no_defs': True} and None
    other.crs))

* Add test intended to catch CRS warning
2017-09-29 17:20:36 +02:00
James McBride fb075e80fa CLN: Remove unused internal function (#569)
_array_input was not used anywhere, and has been sitting around unused
for ~4 years, so far as I can tell.
2017-09-29 09:39:31 +02:00
James McBride 51cbe5bdf0 TST: Add tests for centroid and convex_hull (#568)
Basic tests of methods that were not previously covered.
2017-09-29 09:38:13 +02:00
James McBride 5202d9211d Update CHANGELOG.md
Record improvements and bug fixes in ~month since 0.3.0 release.
2017-09-28 20:48:02 -07:00
Joris Van den Bossche 38458e8d05 TST: addexrGeoDataFrame constructor tests (#495) 2017-09-28 22:45:32 +02:00
Fabien Maussion b9a2d0f39d Add legend_kwds to plot() (#434)
`plot_dataframe` now accepts a `legend_kwds` argument, through which a user can pass keyword arguments accepted by the call to matplotlib's legend function (if `legend=True`).
2017-09-26 16:11:16 -07:00
Andrew Feierman 55d59ee7d5 DOC: Update geocoding.rst (#555) 2017-09-21 17:06:24 +02:00
Joris Van den Bossche 5ae1c65ed1 DOC: add numpydoc to doc build environment 2017-09-21 13:13:36 +02:00
Joris Van den Bossche 5dd32f1fa1 DOC: add mock to doc env file 2017-09-21 11:57:03 +02:00
James McBride abd2864947 ENH: Expose all geopy services (#550)
Use geopy's get_geocoder_for_service to map strings to the proper class
to use, so a geopandas user can use any available geopy Geocoder. Also
provide option to use a Geocoder instance, rather than the string
mapping, which is potentially more transparent.
2017-09-20 21:24:53 +02:00