STOmics / Stereopy

A toolkit of spatial transcriptomic analysis.
MIT License
180 stars 59 forks source link

Can not select any ROI using data.plt.interact_spatial_scatter() #220

Closed cynthier closed 6 months ago

cynthier commented 7 months ago

Hello, I can plot, but I can not select any region using the annotation tool. Everything seems ok and there is no error. Could you please help me? image

%matplotlib inline

import warnings
warnings.filterwarnings('ignore')
import stereo as st
ins = data.plt.interact_spatial_scatter(width=500, height=500, poly_select=True)
ins.show()
cynthier commented 7 months ago

the vesion of stereopy is 0.12.0

cynthier commented 7 months ago

when I run

ins = data.plt.interact_spatial_scatter(width=500, height=500, poly_select=False)
ins.show()

I can select regions but it would not export any data.

Zhenbin24 commented 7 months ago

Hello, if this parameter (poly_select) is False, the tool selected below is a rectangular frame, so your parameter is True. image

In the first step, click the frame selection tool at number 1. In the second step, double-click at the number 2. In the third step, click at the number 3. In the fourth step, double-click at the number 5. This completes the area frame. select. (Tips: Click to select the first position, click at other positions, and finally double-click to end the selection of the area)

1701682905631

Next, you can view the data of the area selected last time. Click the export button and finally execute the ins.add_selected_area() operation,View the selected region data through the ins.selected_exp_data command to ensure that the data is selected

1701682951168

For more details, please refer to the link