CostaLab / CrossTalkeR

R package to do the Ligand Receptor Analysis Visualization
https://costalab.github.io/CrossTalkeR/
MIT License
41 stars 10 forks source link

Error in reading file while using vignette #9

Closed s-yadav21 closed 2 years ago

s-yadav21 commented 3 years ago

Hi, I was trying to run the vignette on my data (two samples - primary tumor and metastatic) and I am getting following error:

Error in read.table(file = file, header = header, sep = sep, quote = quote, : no lines available in input In addition: Warning message: In file(file, "rt") : file("") only supports open = "w+" and open = "w+b": using the former

My data contains read counts- genes are rows and cells as columns.

jsnagai commented 3 years ago

Hi @s-yadav21, could you check if your csv is using comma(",") as separator? The generate_report function provides a field to set a different separator you can easily change it there.

s-yadav21 commented 3 years ago

Hi @jsnagai Thank you very much for such prompt response. Yes my file is comma separated. I used "sep" parameter in generate_report function and I am getting this error. I can't figure out what am I doing wrong.

jsnagai commented 3 years ago

@s-yadav21 it's my pleasure to help!!!

Are you using any character in your cell type name?

s-yadav21 commented 3 years ago

Yes the cell names are alphanumeric.

jsnagai commented 3 years ago

@s-yadav21 Sorry, I meant, do you use the following characters in cell type name: '_' and '\' ?

s-yadav21 commented 3 years ago

Sorry I misunderstood the question, yes my cell types have a special character , colon ' : '

s-yadav21 commented 3 years ago

I removed colon from the cell type names and tried using generate report function. Still getting same error. Reading Files PT "" Error in read.table(file = file, header = header, sep = sep, quote = quote, : no lines available in input In addition: Warning message: In file(file, "rt") : file("") only supports open = "w+" and open = "w+b": using the former

jsnagai commented 3 years ago

@s-yadav21 Would it be possible to you paste the content of you variable path here?

It seems to me that the input is somehow not available, it could happen due to several reasons. Could you double check if you paths to your input files are correct??

Linux version

paths <- c('CTR' = "/home/usr/Documents/CrossTalkeR_test/control_lrgenes.csv", 'EXP' = "/home/usr/Documents/CrossTalkeR_test/exp_lrgenes.csv")

Windows

paths <- c('CTR' = "C:/Users/usr/Documents/CrossTalkeR_test/control_lrgenes.csv", 'EXP' = "C:/Users/usr/Documents/CrossTalkeR_test/exp_lrgenes.csv")

jsnagai commented 3 years ago

@s-yadav21 Does it work?