zktuong / ktplots

Some tools for plotting single-cell data
https://zktuong.github.io/ktplots/
MIT License
162 stars 31 forks source link

Error in `.rowNamesDF<-`(x, value = value) : duplicate 'row.names' #89

Closed lijiaze0331 closed 10 months ago

lijiaze0331 commented 10 months ago

The output files of CellphoneDB V5 such as mean.txt and pvals.txt sometimes exists same 'interacting_pair' like GAL_GALR3. This may cause duplicate row.names in source code of plotcpdb(): row.names(v5tmp) <- paste0(gsub("", "-", v5tmp$interacting_pair), special_sep, v5tmp$variable) 1

zktuong commented 10 months ago

Thanks for raising this bug! It will take me a week+ to implement a fix. Just need to check if i can get around this by forcing the melt to operate on a matrix instead of a dataframe.

zktuong commented 10 months ago

@lijiaze0331 , can you try and reinstall with:

devtools::install_github("zktuong/ktplots", ref="fix-duplicate-rownames")

and see if this helps?

lijiaze0331 commented 10 months ago

@lijiaze0331 , can you try and reinstall with:

devtools::install_github("zktuong/ktplots", ref="fix-duplicate-rownames")

and see if this helps?

Yes, it works. Thanks for your help!