scispy.tl.add_to_shapes

Contents

scispy.tl.add_to_shapes#

scispy.tl.add_to_shapes(sdata, poly, name, centerline=None, shape_key='myshapes', scale_factor=0.50825, target_coordinates='microns', transfo_object_key='images')#

Add shape element to SpatialData.

Parameters:
  • sdata (SpatialData) – SpatialData object.

  • shape_file – coordinates.csv file from xenium explorer (region = “normal_1”) # vi coordinates.csv -> remove 2 first # lines # dos2unix coordinates.csv

  • shape_key (str (default: 'myshapes')) – key of element shape

  • scale_factor (float (default: 0.50825)) – scale factor conversion applied to x and y coordinates for real micron coordinates

  • target_coordinates (str (default: 'microns')) – target_coordinates system