I am required to install pandas using the .py file using the linux command line, before importing pandas once it is installed. If anyone knows how to also do this on macOS that would be appreciated as well.
Thanks
I am required to install pandas using the .py file using the linux command line, before importing pandas once it is installed. If anyone knows how to also do this on macOS that would be appreciated as well.
Thanks
I believe you want to do something like:
import os
cmd = 'sudo pip install pandas'
os.system(cmd)
based on: https://cmdlinetips.com/2014/03/how-to-run-a-shell-command-from-python-and-get-the-output/