Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
71 commits
Select commit Hold shift + click to select a range
311c6e5
fix python <=3.8 compatibility
raphaelquast Jul 12, 2023
b4e5a12
test python 3.8 as well
raphaelquast Jul 12, 2023
5592391
allow set_extent_to_location tests to fail due to connection issues
raphaelquast Jul 13, 2023
50fae4c
rename test-env to eomaps
raphaelquast Jul 13, 2023
12f91c3
remove numpy <1.24 requirement
raphaelquast Jul 13, 2023
2af62bf
Merge branch 'master' into dev
raphaelquast Jul 13, 2023
519122e
change env-name in the docs to "eomaps"
raphaelquast Jul 13, 2023
253a5d2
fix python <=3.8 compatibility
raphaelquast Jul 12, 2023
37b427b
test python 3.8 as well
raphaelquast Jul 12, 2023
027ea43
allow set_extent_to_location tests to fail due to connection issues
raphaelquast Jul 13, 2023
d9ec4d9
rename test-env to eomaps
raphaelquast Jul 13, 2023
9987217
remove numpy <1.24 requirement
raphaelquast Jul 13, 2023
cd7b7cf
Merge branch 'dev' of https://github.com/raphaelquast/EOmaps into dev
raphaelquast Jul 13, 2023
7f9ffb7
improvements for "Add Feature" widget: better menu and individual but…
raphaelquast Jul 17, 2023
d44ad2e
fix add_gdf(set_extent=True) and set default to False
raphaelquast Jul 17, 2023
58b62c1
update button styles
raphaelquast Jul 17, 2023
e6e4a7d
minor
raphaelquast Jul 19, 2023
1705963
fix classification of encoded masked datasets
raphaelquast Jul 19, 2023
4e9d798
add new "contour" shape
raphaelquast Jul 19, 2023
65c6900
add colorbar.indicate_contours() function
raphaelquast Jul 19, 2023
db88df5
depreciate "copy" kwargs of `m.new_layer` and replace them with inher…
raphaelquast Jul 19, 2023
38cac25
add new "contour" shape
raphaelquast Jul 19, 2023
f077893
add colorbar.indicate_contours() function
raphaelquast Jul 19, 2023
f760b31
Merge branch 'contours' of https://github.com/raphaelquast/EOmaps int…
raphaelquast Jul 19, 2023
ab9a39a
remove unnecessary reshape
raphaelquast Jul 19, 2023
b3aa14a
make sure contours are drawn only once
raphaelquast Jul 19, 2023
347fb44
use texts instead of labels for contour-indicators
raphaelquast Jul 19, 2023
9dcd47b
avoid resetting linestyles in layout editor
raphaelquast Jul 19, 2023
cad50f7
allow custom label positions
raphaelquast Jul 19, 2023
8b151cb
remove remaining uses of copy-arguments for new_layer
raphaelquast Jul 20, 2023
1158dcd
fix doc code-block unittests
raphaelquast Jul 20, 2023
f2d170e
propagate depreciated kwargs to new names
raphaelquast Jul 20, 2023
dd024d3
add new "contour" shape
raphaelquast Jul 19, 2023
ba90410
add colorbar.indicate_contours() function
raphaelquast Jul 19, 2023
7ff2c11
remove unnecessary reshape
raphaelquast Jul 19, 2023
1a4849e
make sure contours are drawn only once
raphaelquast Jul 19, 2023
5c74fe8
use texts instead of labels for contour-indicators
raphaelquast Jul 19, 2023
fc613d4
avoid resetting linestyles in layout editor
raphaelquast Jul 19, 2023
e5db4d9
allow custom label positions
raphaelquast Jul 19, 2023
73c8f73
Merge branch 'contours' of https://github.com/raphaelquast/EOmaps int…
raphaelquast Jul 20, 2023
acfd2bb
fix savefig of contours. (make sure _cm_set works with _CollectionAcc…
raphaelquast Jul 20, 2023
db67313
use annotations instead of texts for colorbar contour indicators
raphaelquast Jul 20, 2023
c34e8f9
expose contour_set of _CollectionAccessor:
raphaelquast Jul 20, 2023
d55e1ce
fix AnnotationEditor should only be connected to the parent
raphaelquast Jul 20, 2023
eceb070
add inherit kwargs to new_map
raphaelquast Jul 20, 2023
0b6bb6c
Merge branch 'dev' into contours
raphaelquast Jul 20, 2023
b8567f7
fix typo
raphaelquast Jul 20, 2023
a4ea23c
add unittest for contour plots
raphaelquast Jul 20, 2023
ea9e9a2
fix indicating contours if contour_map is None
raphaelquast Jul 21, 2023
3b27279
add support for contour plots of irregular data
raphaelquast Jul 21, 2023
498a454
test contours from regular and irregular data
raphaelquast Jul 21, 2023
f58b7a8
only classify if levels is None
raphaelquast Jul 21, 2023
3e36f41
fix typo
raphaelquast Jul 21, 2023
d29a040
fix picking of contour-plot artists
raphaelquast Jul 25, 2023
26013ef
fix contour plot levels with custom vmin/vmax
raphaelquast Jul 25, 2023
f6260aa
depreciate "DLR_basemaps" and add all services provided by "DLR"
raphaelquast Jul 26, 2023
19b18f7
add sub-groups for webmap services
raphaelquast Jul 26, 2023
da819bc
Merge branch 'dev' into contours
raphaelquast Jul 26, 2023
396922a
sort webmaps by name in menu
raphaelquast Jul 26, 2023
c9895dd
make sure the help-button is left of the window title
raphaelquast Jul 27, 2023
a8a2999
allow new windows without connecting them to a Maps-object
raphaelquast Jul 27, 2023
152de7a
add map feature information popups to the editor tab
raphaelquast Jul 27, 2023
81d325a
Merge branch 'dev' into contours
raphaelquast Jul 27, 2023
f93e22e
add contour example and use for unittests
raphaelquast Sep 4, 2023
1068688
update docs
raphaelquast Sep 4, 2023
4538ef9
Merge pull request #179 from raphaelquast/contours
raphaelquast Sep 5, 2023
838828f
add image galery on top of example page
raphaelquast Sep 5, 2023
f37271a
minor
raphaelquast Sep 5, 2023
1cfd301
minor
raphaelquast Sep 5, 2023
4043d84
add new feature-info capabilities of the widget to the documentation
raphaelquast Sep 5, 2023
ebcd495
update version to v7.1
raphaelquast Sep 5, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/testMaps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
# set operating systems to test
os: [ubuntu-latest]
# set python versions to test
python-version: ["3.9", "3.10"]
python-version: ["3.8", "3.9", "3.10"]

name: test_Maps ${{ matrix.os }} ${{ matrix.python-version }}
steps:
Expand All @@ -32,7 +32,7 @@ jobs:
miniforge-variant: Mambaforge
miniforge-version: latest

activate-environment: testMaps
activate-environment: eomaps

show-channel-urls: true
use-only-tar-bz2: true
Expand Down
124 changes: 119 additions & 5 deletions docs/EOmaps_examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,85 @@

... a collection of examples that show how to create beautiful interactive maps.


.. |eximg01| image:: _static/fig1.gif
:width: 100%
:align: middle
:target: `ex_1`_
.. |eximg02| image:: _static/fig2.png
:width: 100%
:align: middle
:target: `ex_2`_
.. |eximg03| image:: _static/fig3.gif
:width: 100%
:align: middle
:target: `ex_3`_
.. |eximg04| image:: _static/fig4.gif
:width: 100%
:align: middle
:target: `ex_4`_
.. |eximg05| image:: _static/fig5.gif
:width: 100%
:align: middle
:target: `ex_5`_
.. |eximg06| image:: _static/fig6.gif
:width: 100%
:align: middle
:target: `ex_6`_
.. |eximg07| image:: _static/fig7.gif
:width: 100%
:align: middle
:target: `ex_7`_
.. |eximg08| image:: _static/fig8.gif
:width: 100%
:align: middle
:target: `ex_8`_
.. |eximg09| image:: _static/fig9.gif
:width: 100%
:align: middle
:target: `ex_9`_
.. |eximg10| image:: _static/example_row_col_selector.gif
:width: 100%
:align: middle
:target: `ex_10`_
.. |eximg11| image:: _static/example_inset_maps.png
:width: 100%
:align: middle
:target: `ex_11`_
.. |eximg12| image:: _static/example_lines.png
:width: 100%
:align: middle
:target: `ex_12`_
.. |eximg13| image:: _static/example_gridlines.png
:width: 100%
:align: middle
:target: `ex_13`_
.. |eximg14| image:: _static/example_contour.png
:width: 100%
:align: middle
:target: `ex_14`_

.. |eximg15| replace:: ...


.. table::
:width: 100%

+-----------+-----------+-----------+-----------+-----------+
| |eximg01| | |eximg02| | |eximg03| | |eximg04| | |eximg05| |
+-----------+-----------+-----------+-----------+-----------+
| |eximg06| | |eximg07| | |eximg08| | |eximg09| | |eximg10| |
+-----------+-----------+-----------+-----------+-----------+
| |eximg11| | |eximg12| | |eximg13| | |eximg14| | |eximg15| |
+-----------+-----------+-----------+-----------+-----------+

.. contents:: Contents:
:local:
:depth: 1


.. _ex_1:

Basic data visualization
-------------------------

Expand All @@ -30,6 +104,7 @@ There are 3 basic steps required to visualize your data:
.. image:: _static/fig1.gif
:width: 75%

.. _ex_2:

Customize the appearance of the plot
------------------------------------
Expand All @@ -44,14 +119,15 @@ Customize the appearance of the plot

|toggleStart|

.. literalinclude:: ../tests/example3.py
.. literalinclude:: ../tests/example2.py

|toggleEnd|

.. image:: _static/fig3.png
.. image:: _static/fig2.png
:width: 75%


.. _ex_3:

Data-classification and multiple Maps in a figure
-------------------------------------------------
Expand All @@ -67,14 +143,16 @@ Data-classification and multiple Maps in a figure

|toggleStart|

.. literalinclude:: ../tests/example2.py
.. literalinclude:: ../tests/example3.py

|toggleEnd|

.. image:: _static/fig2.gif
.. image:: _static/fig3.gif
:width: 75%


.. _ex_4:

Callbacks - turn your maps into interactive widgets
---------------------------------------------------

Expand Down Expand Up @@ -102,6 +180,8 @@ Callbacks - turn your maps into interactive widgets
:width: 75%


.. _ex_5:

Overlays, markers and annotations
---------------------------------

Expand All @@ -123,6 +203,9 @@ Overlays, markers and annotations
The data displayed in the above gif is taken from:
- NaturalEarth (https://www.naturalearthdata.com/)


.. _ex_6:

WebMap services and layer-switching
-----------------------------------

Expand All @@ -143,6 +226,8 @@ The data displayed in the above gif is taken from:
- OpenStreetMap hosted by Mundialis (https://www.mundialis.de/en/ows-mundialis/)


.. _ex_7:

Vektor data - interactive geometries
-------------------------------------

Expand Down Expand Up @@ -178,6 +263,8 @@ The data displayed in the above gif is taken from:
- NaturalEarth (https://www.naturalearthdata.com/)


.. _ex_8:

Using Scalebars
---------------

Expand Down Expand Up @@ -217,6 +304,8 @@ The data displayed in the above gif is taken from:



.. _ex_9:

Data analysis widgets - Timeseries and histograms
-------------------------------------------------

Expand All @@ -238,6 +327,8 @@ This example shows how to use EOmaps to analyze a database that is associated wi
:width: 75%


.. _ex_10:

Data analysis widgets - Select 1D slices of a 2D dataset
--------------------------------------------------------

Expand All @@ -259,7 +350,7 @@ Use custom callback functions to perform arbitrary tasks on the data when clicki
:width: 75%


.. _EOmaps_examples_inset_maps:
.. _ex_11:

Inset-maps - get a zoomed-in view on selected areas
---------------------------------------------------
Expand All @@ -285,6 +376,8 @@ Quickly create nice inset-maps to show details for specific regions.
:width: 75%


.. _ex_12:

Lines and Annotations
---------------------

Expand All @@ -310,6 +403,7 @@ Connect the anchor-points via:
:width: 75%


.. _ex_13:

Gridlines and Grid Labels
-------------------------
Expand All @@ -327,3 +421,23 @@ Draw custom grids and add grid labels.

.. image:: _static/example_gridlines.png
:width: 75%

.. _ex_14:

Contour plots and Contour Levels
--------------------------------

Use the ``contour``-shape to draw contour-plots of regular (or irregular data)
or to indicate contour-levels on top of other plots.

(requires EOmaps >= v7.1)

|toggleStart|

.. literalinclude:: ../tests/example_contour.py

|toggleEnd|


.. image:: _static/example_contour.png
:width: 75%
5 changes: 3 additions & 2 deletions docs/FAQ.rst
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ simply provide it as an explicit argument!
---------------------------

General changes in behavior
+++++++++++++++++++++++++++
~~~~~~~~~~~~~~~~~~~~~~~~~~~

- | 🔶 Starting with EOmaps v6.0 multiple calls to ``m.plot_map()``
| **on the same Maps-object completely remove (and replace)** the previous dataset!
Expand All @@ -226,7 +226,8 @@ General changes in behavior
- the ordering of artists inside a layer is determined by their ``zorder`` (e.g. ``m.plot_map(zorder=123)``)

Removed (previously depreciated) functionalities
++++++++++++++++++++++++++++++++++++++++++++++++
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

- ❌ the ``m.figure`` accessor has been removed!

- Use ``m.ax``, ``m.f``, ``m.colorbar.ax_cb``, ``m.colorbar.ax_cb_plot`` instead
Expand Down
Binary file added docs/_static/example_contour.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 18 additions & 0 deletions docs/api_companion_widget.rst
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,21 @@ EOmaps comes with an awesome companion widget that provides many useful features
matplotlib.use("qt5agg")

For more details, have a look at :ref:`configuring_the_editor`.



Additional information on Features and WebMaps
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Starting with EOmaps v7.1 the widget provides a new useful functionality to **quickly access important
information** of :ref:`Features <ne_features>` and :ref:`WebMaps <webmap_layers>` that were used to create a map.

If there is additional information available for an artist of a map, a |question_symbol| symbol will appear
next to the corresponding entry in the **Edit** tab that will open a popup window containing the following information:

- **Notes** and **infos** on the features
- Links to **sources**, **references** and **licensing details** (without warranty for correctness!)
- The **source code** to reproduce the current appearance of the feature

.. image:: _static/minigifs/companion_widget_feature_info.gif
:width: 50%
22 changes: 11 additions & 11 deletions docs/api_data_visualization.rst
Original file line number Diff line number Diff line change
Expand Up @@ -180,13 +180,13 @@ Possible shapes that work nicely for datasets with up to ~500 000 data-points:
delaunay_triangulation



Possible shapes that work nicely for up to a few million data-points:

.. autosummary::
:nosignatures:

raster
contour


While :py:class:`raster` can still be used for datasets with a few million datapoints, for extremely large datasets
Expand Down Expand Up @@ -218,7 +218,7 @@ Possible shapes that can be used to quickly generate a plot for extremely large
m2 = m.new_layer() # create a new Maps-object on the same layer
m2.set_data(data, x, y) # assign another dataset to the new Maps object
m2.set_shape.geod_circles(radius=50000, # draw geodetic circles with 50km radius
n=100) # use 100 intermediate points to represent the shape
n=100) # use 100 intermediate points to represent the shape
m2.plot_map(ec="k", cmap="Reds", # plot the data
zorder=2, set_extent=False) # (and avoid resetting the plot-extent)

Expand Down Expand Up @@ -428,25 +428,25 @@ To apply a uniform color to all datapoints, you can use `matpltolib's named colo
m.set_data(data=None, x=[10,20,30], y=[10,20,30])

# Use any of matplotlibs "named colors"
m1 = m.new_layer(copy_data_specs=True)
m1 = m.new_layer(inherit_data=True)
m1.set_shape.ellipses(radius=10)
m1.plot_map(fc="r", zorder=0)

m2 = m.new_layer(copy_data_specs=True)
m2 = m.new_layer(inherit_data=True)
m2.set_shape.ellipses(radius=8)
m2.plot_map(fc="orange", zorder=1)

# Use RGB or RGBA tuples
m3 = m.new_layer(copy_data_specs=True)
m3 = m.new_layer(inherit_data=True)
m3.set_shape.ellipses(radius=6)
m3.plot_map(fc=(1, 0, 0.5), zorder=2)

m4 = m.new_layer(copy_data_specs=True)
m4 = m.new_layer(inherit_data=True)
m4.set_shape.ellipses(radius=4)
m4.plot_map(fc=(1, 1, 1, .75), zorder=3)

# For grayscale use a string of a number between 0 and 1
m5 = m.new_layer(copy_data_specs=True)
m5 = m.new_layer(inherit_data=True)
m5.set_shape.ellipses(radius=2)
m5.plot_map(fc="0.3", zorder=4)

Expand All @@ -466,26 +466,26 @@ To explicitly color each datapoint with a pre-defined color, simply provide a li

# Use any of matplotlibs "named colors"
# (https://matplotlib.org/stable/gallery/color/named_colors.html)
m1 = m.new_layer(copy_data_specs=True)
m1 = m.new_layer(inherit_data=True)
m1.set_shape.ellipses(radius=10)
m1.plot_map(fc=["indigo", "g", "orange"], zorder=1)

# Use RGB tuples
m2 = m.new_layer(copy_data_specs=True)
m2 = m.new_layer(inherit_data=True)
m2.set_shape.ellipses(radius=6)
m2.plot_map(fc=[(1, 0, 0.5),
(0.3, 0.4, 0.5),
(1, 1, 0)], zorder=2)

# Use RGBA tuples
m3 = m.new_layer(copy_data_specs=True)
m3 = m.new_layer(inherit_data=True)
m3.set_shape.ellipses(radius=8)
m3.plot_map(fc=[(1, 0, 0.5, 0.25),
(1, 0, 0.5, 0.75),
(0.1, 0.2, 0.5, 0.5)], zorder=3)

# For grayscale use a string of a number between 0 and 1
m4 = m.new_layer(copy_data_specs=True)
m4 = m.new_layer(inherit_data=True)
m4.set_shape.ellipses(radius=4)
m4.plot_map(fc=[".1", ".2", "0.3"], zorder=4)

Expand Down
2 changes: 1 addition & 1 deletion docs/api_inset_maps.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ For convenience, inset-map objects have the following special methods defined:
InsetMaps.add_indicator_line


Checkout the associated example on how to use inset-maps: :ref:`EOmaps_examples_inset_maps`
Checkout the associated example on how to use inset-maps: :ref:`ex_11`

To quickly re-position (and re-size) inset-maps, have a look at the :ref:`layout_editor`!

Expand Down
2 changes: 1 addition & 1 deletion docs/contribute_env.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: testMaps
name: eomaps
channels:
- conda-forge

Expand Down
Loading