I'm writing a Python code which uses R scripts by calling them trough subprocess.run(). The R script I try to call works as supposed when I call it from PowerShell by command: & 'C:\...\RScript.exe' .\script.R . However, when I try to call the same script through Python's subprocess.run() it trows the following error:
Loading required package: ggplot2
Error: package or namespace load failed for 'ggplot2' in loadNamespace(j