SpatioTemporalTraits
SpatioTemporalTraits.assert_timedim_last
— Methodassert_timedim_last(x)
Throw an error if the x
has a time dimension that is not the last dimension.
SpatioTemporalTraits.depth
— Methoddepth(x)
Returns the size of the dimension corresponding to depth.
SpatioTemporalTraits.duration
— Methodduration(x)
Duration of the event along the time axis.
SpatioTemporalTraits.has_timedim
— Methodhas_timedim(x) -> Bool
Returns 'true' if x
has a time dimension.
SpatioTemporalTraits.height
— Methodheight(x)
Returns the size of the dimension corresponding to height.
SpatioTemporalTraits.is_spatial
— Methodis_spatial(x::StaticSymbol) -> StaticBool
Returns static(true)
if x
refers to a spatial dimension. By default, any dimension that is not one of the following is considered spatial:
- time, Time
- channels, Channels
- observations, Observations, obs
SpatioTemporalTraits.is_temporal
— Methodis_temporal(x) -> StaticBool
Returns True
if x
refers to time.
SpatioTemporalTraits.ntimes
— Methodntimes(x) -> Integer
Returns the number of elements along the time dimension.
SpatioTemporalTraits.origin
— Methodorigin(x) -> Tuple
Returns the spatial origin of x
.
SpatioTemporalTraits.pixel_spacing
— Methodpixel_spacing(x)
Return a tuple representing the separation between adjacent pixels along each axis of the image. Derived from the step size of each element of spatial_indices
.
SpatioTemporalTraits.sampling_rate
— Methodsampling_rate(x)
Number of samples per second.
SpatioTemporalTraits.sdims
— MethodSpatioTemporalTraits.spatial_directions
— Methodspatial_directions(img) -> (axis1, axis2, ...)
Return a tuple-of-tuples, each axis[i]
representing the displacement vector between adjacent pixels along spatial axis i
of the image array, relative to some external coordinate system ("physical coordinates").
By default this is computed from pixel_spacing
, but you can set this manually using ImageMeta.
SpatioTemporalTraits.spatial_first
— Methodspatial_first(x)
The first position along each spatial indices (i.e., where each spatial axis starts).
SpatioTemporalTraits.spatial_indices
— Methodspatial_indices(x)
Returns the keys along each spatial dimension.
SpatioTemporalTraits.spatial_last
— Methodspatial_last(x)
The last position along each spatial indices (i.e., where each spatial axis stops).
SpatioTemporalTraits.spatial_order
— Methodspatial_order(x) -> Tuple
Returns the dimnames
of x
that correspond to spatial dimensions, as determined by is_spatial
. At most three dimensions will be considered spatial.
SpatioTemporalTraits.spatial_units
— Methodspatial_units(x)
Returns the Unitful.unit
along all spaial dimensions.
SpatioTemporalTraits.spatialdims
— Methodspatialdims(x) -> Tuple{Vararg{StaticInt}}
Return a tuple of the spatial dimensions of x
.
SpatioTemporalTraits.temporal_units
— Methodtemporal_units(x)
Returns the Unitful.unit
along the time dimensions.
SpatioTemporalTraits.time_first
— Methodtime_first(x)
First time point along the time axis.
SpatioTemporalTraits.time_last
— Methodtime_last(x)
Last time point along the time axis.
SpatioTemporalTraits.time_step
— Methodtime_step(x)
The time step/interval between each element.
SpatioTemporalTraits.timedim
— Methodtimedim(::Type{T}) -> Integer
Returns the dimension associated with time.
SpatioTemporalTraits.times
— Methodtimes(x)
Returns a collection of times associated with x
. If x
has a specific dimension associated with time, this returns the keys along that dimension.
SpatioTemporalTraits.width
— Methodwidth(x)
Returns the size of the dimension corresponding to width.