Is there a way to run all the cells in a notebook, as in Jupyter restart kernel and run all cells?
Refresh the browser.
Observable notebooks are reactive, so even that will not be needed in most cases, as cells automatically recompute their values when any of the values they depend upon are changed.
Can you share a notebook with a specific example that prompted your question?
Edit: I noticed you posted this question in two separate places. It’s best to have one thread per question, so that answers can be centralized and to avoid duplication of effort.
another solution is to create a “replay” button, that will send a message when clicked, then all cells that depend on it will refresh. Very useful when you want to see an algorithm unfold several times.
examples abound — see for instance https://observablehq.com/@fil/som-tsp
Jupyter notebook has an interface to run entire notebook, sequentially running all cells.
How can we do that in ObservableHQ?
You could refresh the page to rerun all the cells. What’s your use case?
In Observable, cells run automatically when things change, and they run in topological order (based on dependencies), rather than document order. The behavior is described here:
You can run the current cell using Shift-Enter.
Thanks, referring cell by name should help me a lot so that I can explicitly add dependencies.