Helper function to install packages for R using an external 'requirements.txt' or a string containing diverse packages from several resources like Github or CRAN.