comparison docs/src/grids_and_grid_functions.md @ 1631:ee3fc2d83c73 feature/grids/plotting

Write out available plot methods in docs
author Jonatan Werpers <jonatan@werpers.com>
date Tue, 25 Jun 2024 08:38:08 +0200
parents 08f06bfacd5c
children
comparison
equal deleted inserted replaced
1630:27d270c9cb89 1631:ee3fc2d83c73
5 The module also has functionality for creating and working with grid functions. 5 The module also has functionality for creating and working with grid functions.
6 6
7 ## Interface for grids 7 ## Interface for grids
8 All grids are expected to work as a grid function for the coordinate function, and thus implements Julia's Indexing- and Iteration-interfaces. Notably they are *not* abstract arrays because that inteface is too restrictive for the types of grids we wish to implement. 8 All grids are expected to work as a grid function for the coordinate function, and thus implements Julia's Indexing- and Iteration-interfaces. Notably they are *not* abstract arrays because that inteface is too restrictive for the types of grids we wish to implement.
9 9
10
11 ## Plotting
12 Plotting of grids and grid functions is supported through a package extension with Makie.jl.
13
14 For grids we have:
15 * `plot(::Grid{<:Any,2})` (same as `lines`)
16 * `lines(::Grid{<:Any,2})`
17 * `scatter(::Grid{<:Any,2})`
18
19 For 1D grid functions we have:
20 * `plot(::Grid{<:Any,1}, ::AbstractVector)` (same as `lines`)
21 * `lines(::Grid{<:Any,1}, ::AbstractVector)`
22 * `scatter(::Grid{<:Any,1}, ::AbstractVector)`
23
24 For 2D grid functions we have:
25 * `plot(::Grid{<:Any,2}, ::AbstractArray{<:Any,2})` (constructs a 2d mesh)
26 * `surface(::Grid{<:Any,2}, ::AbstractArray{<:Any,2})`
27
10 ## To write about 28 ## To write about
11 <!-- # TODO: --> 29 <!-- # TODO: -->
12 * Grid functions 30 * Grid functions
13 * Basic structure 31 * Basic structure
14 * Indexing 32 * Indexing