Skip to content

2D plots ​

The 2D plots show resistivity sections, the mesh, and the apparent resistivity and phase at each station. They are written as PNG files and need no display, so they also work in batch jobs.

Plot an inversion ​

After a deterministic or VFSA inversion, one call writes all the standard plots into the run's plots/ folder:

julia
PlotInversion2D(run; true_model_path = "model.true", maximum_depth_km = 10)

You get the mesh, the start and final models, the data fit and the convergence. A VFSA run adds the median, best, 5 %, 95 % and standard deviation models of the ensemble.

Plot a model file ​

julia
PlotModel2D("model.rho"; output_path = "Model.png", maximum_depth_km = 10, show_padding = false)
  • maximum_depth_km cuts the section at that depth.

  • show_padding = false shows only the core of the mesh, under the stations.

  • resistivity_log10_range sets the colour scale, (0.0, 4.0) by default (1 to 10 000 Ω·m).

Plot data ​

julia
PlotData2D("data.dat"; output_path = "Data.png")
PlotData2D("data.dat"; predicted_path = "data.pred", output_path = "DataFit.png")

The first line plots the observed TE and TM curves of every station. With predicted_path the predicted curves are drawn on top, so you can see where the model fits and where it does not. Use station_indices = 1:5 to plot only some stations.

Build your own figure ​

For figures that are not covered above, use the building blocks that work on a mesh and a resistivity array in memory: plot_mt2d_model, plot_mt2d_mesh, plot_mt2d_data_fit, plot_mt2d_site_curves and the convergence plots plot_inv2d_convergence and plot_vfsa2d_convergence. They take the same keywords as the functions above.