SBOHVM / RPiR

The Reproducible Programming in R course, developed by the School of Biodiversity, One Health and Veterinary Medicine at the University of Glasgow.
https://sbohvm.github.io/RPiR/
GNU General Public License v3.0
12 stars 2 forks source link

Cannot access other's packages #224

Closed McGhee-Will closed 3 years ago

McGhee-Will commented 3 years ago

Hi @richardreeve @soniamitchell, I still cannot access the packages made by others. I downloaded them using the method we used in practical series 2 and when I try to run the demo it says:

Error in find.package(package, lib.loc, verbose = verbose) : there is no package called ‘hanamayallSeries03’

Any idea on how to fix this? Cheers.

McGhee-Will commented 3 years ago

I figured it out, sorry to bother you 🥇

soniamitchell commented 3 years ago

Awesome! Hopefully your solution involved using install_github() rather than the method we used in Series 2?

McGhee-Will commented 3 years ago

I said that and now it won't work again... I managed to run the demo but when I try to compile the html report it says the package doesn't exist

soniamitchell commented 3 years ago

Hmm... try restarting R, then try compiling the notebook. If there's an error, could you take a screenshot?

Also, could you install using install_github() before running demo(), though install() works fine, we're trying to simulate installing peoples packages from GitHub without having to make clones of their repositories 👍

soniamitchell commented 3 years ago

Also, check to see if library(theirpackage) is called at the top of their script

McGhee-Will commented 3 years ago

When I try to use install_github() it comes up with this:

devtools::install_github("IBAHCM/hanamayallSeries03") Error: Failed to install 'unknown package' from GitHub: HTTP error 404. Not Found

Did you spell the repo owner (IBAHCM) and repo name (hanamayallSeries03) correctly?

After bringing it into R using the other method, I used populate_packages to get the demo to work but the html compiling didn't work

McGhee-Will commented 3 years ago

and the library(theirpackage) is at the top

soniamitchell commented 3 years ago

hmm.. it works fine for me.. I think one of the students that stayed late had a similar problem. The solution was to try installing the package using a similar method to that used in Series 2 (as you no doubt discovered). By cloning the repository, then using devtools::install(). Does that work?

McGhee-Will commented 3 years ago

Yes! Thank you