moscot.problems.space.MappingProblem.spatial_correspondence¶
- MappingProblem.spatial_correspondence(interval=10, max_dist=None, attr=None)¶
Compute structural correspondence between spatial and molecular distances.
- Parameters:
interval (
Union
[int
,ndarray
[Any
,dtype
[floating
]],Array
]) – Interval for the spatial distance. Ifint
, it will be set from the data.max_dist (
Optional
[int
]) – Maximum distance for the interval. IfNone
, it will set from the data.attr (
Optional
[Dict
[str
,Optional
[str
]]]) –How to extract the data for correspondence. Valid options are:
- Return type:
- Returns:
: A dataframe with the following columns:
'features_distance'
- average spatial distance.'index_interval'
- index of the interval.'value_interval'
- average expression distance.'{batch_key}'
key of the batch (slide).