OceanRobots.jl icon indicating copy to clipboard operation
OceanRobots.jl copied to clipboard

adding coastlines to float positions plot in `ArgoFloat.jl`

Open ggebbie opened this issue 2 years ago • 1 comments

To add coastlines to the float positions plot in the Pluto notebook, ArgoFloat, is the best approach to follow instructions from GeoMakie? This would involve making a GeoAxis, I believe.

An alternative workflow would be using PythonPlot and cartopy, but I assume that this would pull in many dependencies, be difficult to maintain, and might not plot well in Pluto notebooks.

ggebbie avatar Sep 27 '23 13:09 ggebbie

I took the approach of turning the "positions and speed" panel into a GeoAxis plot using GeoMakie. My experiment didn't (so far) give production-quality results. Some issues with GeoMakie:

  1. some projections gave horizontal lines across the domain (workaround, put longitude between -180 and 180
  2. frame of plot does not enclose all coastlines
  3. difficult to layout a GeoAxis with other panels that are regular Axis plots (size and labels change when in a complex layout)
  4. one projection worked ok (ortho), others did not work at all.

I will submit a PR so that the code is available, perhaps for being fixed in the future. I doubt you will want to merge it.

ggebbie avatar Oct 07 '23 02:10 ggebbie

To add coastlines to the float positions plot in the Pluto notebook, ArgoFloat, is the best approach to follow instructions from GeoMakie? This would involve making a GeoAxis, I believe.

An alternative workflow would be using PythonPlot and cartopy, but I assume that this would pull in many dependencies, be difficult to maintain, and might not plot well in Pluto notebooks.

We have been making progress on this in GeoMakie.jl but there are still issues (see https://github.com/MakieOrg/GeoMakie.jl/pull/228 ).

However, I have a working version in the MeshArrays+Makie extension (e.g., projmap) that does this in the geography notebook. Code is in the Pluto notebook file which should run right away.

ps. Sorry for the lag in response.

gaelforget avatar May 21 '24 13:05 gaelforget

See https://github.com/JuliaOcean/OceanRobots.jl/pull/59#issuecomment-2134194805a

Closing for now. Should revisit use of GeoMakie later.

gaelforget avatar May 28 '24 01:05 gaelforget