navinlabcode / CellTrek

95 stars 18 forks source link

Celltrek output to spot and cell mapping #30

Open smk5g5 opened 12 months ago

smk5g5 commented 12 months ago

Hi,

I recently started using Celltrek. I am trying to understand how to interpret the x and y coordinate output in celltrek data.

My celltrek results are interpolated (for the visium data) to show cells between the spots. I am trying to understand or accurately decipher the tumor proportions for each site. I was looking at the image output of the Seurat object and the celltrek output. Do the two things mean the same?

> head(samp_celltrek$coord_x)
Other_10X249_2.CTGTAGACAGGCATTT.5 Other_10X175_2.TCTCAGCAGTGACACG.5
                         7084.793                          7076.214
Other_10X264_3.TAACGACAGGCGTCCT.5 Other_10X249_2.CCTCACAGTGGCCTCA.5
                         7062.018                          7095.788
Other_10X249_4.GTTGCGGAGGATTTCC.5 Other_10X265_5.TTTGGTTAGCCGGATA.5
                         7066.821                          7091.498
> head(samp_celltrek$coord_y)
Other_10X249_2.CTGTAGACAGGCATTT.5 Other_10X175_2.TCTCAGCAGTGACACG.5
                         7656.116                          7638.562
Other_10X264_3.TAACGACAGGCGTCCT.5 Other_10X249_2.CCTCACAGTGGCCTCA.5
                         7643.233                          7639.805
Other_10X249_4.GTTGCGGAGGATTTCC.5 Other_10X265_5.TTTGGTTAGCCGGATA.5
                         7634.537                          7648.865

sum(table(samp_celltrek$clean_cell_type[grep(7077,samp_celltrek$coord_x)])) sum(table(samp_celltrek$clean_cell_type[grep(7642,samp_celltrek$coord_y)]))

I see there is a difference here which is possible because of the interpolation celltrek does for 10x visium for cells which may lie between two spots.

But is this the correct understanding of the output or is there a more accurate way to get the cells/celltypes for a particular spot? Kindly let me know.

Thank you!