environmentaltools.graphics.plot_ascifiles

environmentaltools.graphics.plot_ascifiles(data, title=None, fname=None, ax=None)[source]

Plot data from ASCII grid files.

Displays raster data with contour lines, typically used for DEM (Digital Elevation Model) or bathymetry visualization from ASCII format files.

Parameters:
  • data (dict) – Dictionary containing ‘x’, ‘y’, and ‘z’ arrays representing grid coordinates and elevation/depth values.

  • title (str, optional) – Plot title. Defaults to None.

  • fname (str, optional) – Filename to save the figure. Defaults to None.

  • ax (matplotlib.axes.Axes, optional) – Axes object to plot on. Defaults to None.

Returns:

The axes object with the plot.

Return type:

matplotlib.axes.Axes