erlab.analysis.mask#

Functions related to masking.

Polygon masking is adapted from the CGAL library. More information on point-in-polygon strategies can be found in Ref. [3].

Modules#

polygon

Polygon mask generation code adapted from the CGAL C++ library.

Functions

hex_bz_mask_points(x, y[, a, rotate, ...])

Returns a mask for given points.

mask_with_hex_bz(kxymap[, a, rotate, invert])

Returns map masked with a hexagonal BZ.

mask_with_polygon(arr, vertices[, dims, invert])

polygon_mask(vertices, x, y[, invert])

polygon_mask_points(vertices, x, y[, invert])

erlab.analysis.mask.mask_with_polygon(arr, vertices, dims=('kx', 'ky'), invert=False)[source]#
erlab.analysis.mask.polygon_mask(vertices, x, y, invert=False)[source]#
erlab.analysis.mask.polygon_mask_points(vertices, x, y, invert=False)[source]#
erlab.analysis.mask.mask_with_hex_bz(kxymap, a=3.54, rotate=0, invert=False)[source]#

Returns map masked with a hexagonal BZ.

erlab.analysis.mask.hex_bz_mask_points(x, y, a=3.54, rotate=0, offset=None, reciprocal=False, invert=False)[source]#

Returns a mask for given points.