New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Autoexecute ipython notebook cells just like in Mathcad #3164
Comments
I think we'd only want to provide this if we could be confident it would work really well, because if people think it's automatically updating everything, they may not notice if something isn't up to date. |
I don't think we would implement this in IPython proper, but it shouldn't be difficult to implement this in a javascript notebook extension (custom.js). |
This is the main idea behind my new sage "interact" implementation: snippets of code that track dependencies and automatically update when a dependency is changed. |
@takluyver The implementation will always keep the notebook uptodate. if not then it is a buggy implementation. @jasongrout can the sage interact feature be backported to ipython? |
Yes, I mean that a buggy implementation would be worse than not having this, because people would try to rely on it. And I think that a bug-free implementation would be quite hard to do, because Python is so flexible. For instance:
Now you have to track a dictionary holding a method which holds a bound reference to |
How about making the dependencies explicit? I mean if I can mark cell A being dependent on B then I can automatically trigger A if B is changed. I am currently thinking about a similar thing meaning that the extension I am looking for could check before the execution of A if B was already executed/triggers B before A. That might make the case much easier. P.S. Oh I did not see that this was 5 years ago. |
Similar to Mathcad add autorun capability to ipython notebooks.
for eg
If you now alter In [1] and make x = 2, ipython should then autoexecute the In [3] cell because one of it's dependencies has changed, x is no longer 1 and the value of y is now dirty. After re-evaluate In [3] the Out [3] should now show 5. Since In [2] doesn't depend on x it shouldn't be re-evaluated. This will speed up computations in complex and long notebooks.
The text was updated successfully, but these errors were encountered: