Ask Your Question
2

In Sage Notebook, does sage compile all programs in a cell ?

asked 4 years ago

andriam gravatar image

updated 4 years ago

Sometimes, in Sagenotebook, when I put many programs in the same cell, for example, the definition of a class, methods within this class and functions , it seems that Sage compiles the class defintions and methods, but ignores the functions.

Preview: (hide)

1 Answer

Sort by » oldest newest most voted
3

answered 4 years ago

slelievre gravatar image

If your question is

then one solution is

from IPython.core.interactiveshell import InteractiveShell
InteractiveShell.ast_node_interactivity = "all"
Preview: (hide)
link

Comments

This should be mentioned in the documentation...

Emmanuel Charpentier gravatar imageEmmanuel Charpentier ( 4 years ago )

Nice. Is there a similar option for SageCell?

mwageringel gravatar imagemwageringel ( 4 years ago )

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 4 years ago

Seen: 247 times

Last updated: Aug 14 '20