I was working on a long Jupyter notebook and for some reason I had to close it and restart. After that, I'd like to run all the code before the line I was working on. Is there a convenient way to do this?
I was working on a long Jupyter notebook and for some reason I had to close it and restart. After that, I'd like to run all the code before the line I was working on. Is there a convenient way to do this?
just add a cell and paste these lines of code at the point to which you want all cells to run and run this cell, all above cells will run automatically one by one.
from IPython.display import Javascript
display(Javascript('IPython.notebook.execute_cells_above()'))