I\'m wondering if it\'s possible to populate sys.argv
(or some other structure) with command line arguments in a jupyter/ipython notebook, similar to how it\'s
I assume that you just want to parse some arguments to the notebooks, but it's not necessary to use the command line.
If you want to parse commands like.
python script.py --a A --b B
You can use the following code in the notebook:
cmd = '--a A --b B'
args = args = parser.parse_args(cmd)
For parse_args
, you can find more information here.