BIMSBbioinfo / VoltRon

Spatial omic analysis toolbox for multi-resolution and multi-omic integration using image registration
http://bioinformatics.mdc-berlin.de/VoltRon/
Other
36 stars 9 forks source link

voltron with jupyter notebook #144

Open smc9477 opened 2 weeks ago

smc9477 commented 2 weeks ago

Thank you for creating such a great tool. I am trying to perform an analysis on a Jupyter Notebook using a conda environment as the kernel on a Linux server. However, the IP I can use is fixed, and it seems that the registerSpatialData function does not allow me to fix the IP. Additionally, due to server policies, I am unable to use RStudio.

Could you please suggest what I can do in this situation?

Artur-man commented 1 week ago

Hello there,

Thanks so much <3

Hmm perhaps I can configure the port where it can be an option for any function that requires shiny applications. As an alternative, if you wanna use VoltRon in a jupyter notebook (with R kernel?) perhaps we can trigger shiny using htmlwidgets which is supported in Jupyter notebooks. Would you also prefer that ?

Artur-man commented 1 week ago

I have pushed an update to the shiny-based routines to recognize options from the shinyApp function. Hence now you can pass information on host and port. Wanna give it a try?

annotateSpatialData(visium_data, shiny.options = list(host = "127.0.0.1", port = 6356))

vrSpatialPlot(visium_data, interactive = TRUE, shiny.options = list(port = 6356))

annotateSpatialData(visium_data, shiny.options = list(port = 6356))

registerSpatialData(reference_spatdata = visium_data, 
                    query_spatdata = visium_data, 
                    shiny.options = list(host = "127.0.0.1", port = 6356))

The update is on dev now. Please remove the R package, restart R session and download VoltRon from dev branch again to try.

smc9477 commented 5 days ago

thank you for update function.

i've removed the R package and re-download from dev, but still there is no shiny.options at registerSpatialData function. could you chek it? Thank you for your time

Artur-man commented 5 days ago

Hello there, I have just tried pulling from the dev branch to see if it is working, and it does: devtools::install_github("BIMSBbioinfo/VoltRon@dev")

Reinstalling R packages are bit more tricky then it should be, you have to make sure that you deleted it by attemping to delete twice, and restart the R session before downloading, otherwise you get the same package ... also main branch still doesnt have the modification