I am using the terminal in jupyter and am trying to plot with matplotlib. I need to plot inline and so i use %matplotlib inline but i am getting the following error:
>>> %matplotlib inline File "<stdin>", line 1 %matplotlib inline ^ SyntaxError: invalid syntax Why am i getting this error? Is it because it is a terminal and not jupyter notebook type environment? I had tried the same code in jupyter notebook and it did not return any errors.
%whateveris an IPython magic command, which will only work in IPython (Jupyter uses IPython kernel by default).