federicomarini/pcaExplorer

App crashing when uploading data. Issue with row.names option in read.delim

Closed this issue · 6 comments

Hoohm commented

Hello,

I'm trying to implement pcaExplorer on our local network so that our lab can use it from any computer directly on the server.

I'm having an issue when I use the upload tool after running pcaExplorer() without any options.
I think it comes because the read.delim used in pcaExplorer.R at line 822 doesn't take the first column as rownames.

cm <- utils::read.delim(input$uploadcmfile$datapath, header = TRUE, as.is = TRUE, sep = "\t", quote = "", ## TODO: tell the user to use tsv, or use heuristics ## to check what is most frequently occurring separation character? -> see sepGuesser.R check.names = FALSE)
Changing it to :
cm <- utils::read.delim(input$uploadcmfile$datapath, header = TRUE, as.is = TRUE, sep = "\t", quote = "", row.names = 1, ## TODO: tell the user to use tsv, or use heuristics ## to check what is most frequently occurring separation character? -> see sepGuesser.R check.names = FALSE)

should fix that issue. I've tested it by running pcaExplorer(countmatrix =local_count, coldata=local_meta) using the exact same functions than here. Running it with the first version doesn't allow you to run the app with the same error when uploading it. The second version fixes that.

Thanks

Patrick

Hi Patrick,

Thanks for your feedback. I could set it as an option in the file upload panel.
But it seems there will be no problems in just changing the option in the way you propose.

I'll edit this accordingly - in the end, it is not a bad thing to "force" users to have meaningful data structures.

Please feel free to report more of these issues, sometimes a fresh pair of eyes (and users) can just be good for the software

Hoohm commented

I was going to propose more features :)

I was thinking of making something similar to what you have written but less complete.
So finding your pcaExplorer is amazing! I would need DEA in there. Have you planned to add it or not? If not, I might just start trying to implement it myself into your app. I have never tried to code shiny apps so, no promises ;)

Good to hear!
For the DE analysis I am coming up with a similar dashboard, which is currently in testing mode - so it should not take too long to get it done. As soon as it is somehow stable, I will put it on github. If you want, you can send me a PM/email with the features you would like to have, so I can already check if it is there or if I missed something relevant.

Hoohm commented

Will do!

The requested fix should now be up and running ;)

Hoohm commented

It fixed the problem.
Thanks