from matplotlib import pyplot as plt
tSNE_data = np.stack((ds.ca._tSNE_1, ds.ca._tSNE_2))
df_tSNE = pd.DataFrame(data = tSNE_data, index=['tSNE1', 'tSNE2'], columns=ds.ca.CellID)
#NOTE: this includes all excluded cells. Their coordinates are (0,0)
#select included cells using the "Valid" attribute: df.loc[:, ds.ca.Valid == 1]
plt.figure(figsize=(4, 4))
plt.scatter(df_tSNE.loc['tSNE1', ds.ca.Valid == 1], df_tSNE.loc['tSNE2', ds.ca.Valid == 1], s=2)
plt.show()
但是在datalore里面运行没有图像结果