vjcitn / CDNMscrna

materials for single-cell RNA-seq workshop at Channing
https://vjcitn.github.io/CDNMscrna/
0 stars 1 forks source link

setting correct python environment? #4

Open mikecho95 opened 1 month ago

mikecho95 commented 1 month ago

Vince - here:


import scanpy as sc
pp3k = sc.datasets.pbmc3k()
pp3k
...

I have a python environment called singleCell which has the right packages, but how do I make my ride / RStudio session use it?
vjcitn commented 1 month ago

OK -- in quarto I was unable to get this to work so I comment it out. If you want to do it interactively, what I would do is set the environment variable RETICULATE_PYTHON to the path to your python executable that knows how to load the packages of interest. I think you may need to start R again after doing that, or you could try Sys.setenv for this.