We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc3c098 commit 582c837Copy full SHA for 582c837
src/spatialdata_plot/_accessor.py
@@ -0,0 +1,18 @@
1
+import spatialdata as sd
2
+from xarray.core.extensions import _register_accessor
3
+
4
5
+def register_spatial_data_accessor(name: str) -> sd.SpatialData:
6
+ """Hijacks xarray _register_accessor to register a SpatialData accessor.
7
8
+ Parameters
9
+ ----------
10
+ name : str
11
+ Name under which the accessor should be registered. A warning is issued
12
+ if this name conflicts with a preexisting attribute.
13
14
+ See Also
15
+ --------
16
+ register_dataset_accessor
17
+ """
18
+ return _register_accessor(name, sd.SpatialData)
0 commit comments