In mathematic Sage Cells several programming languages can be used. Most popular, at least by me, are probably python > sage > r. This page discusses and demonstrates the difference between the former two.
Matplotlib is a common python library used throughout this website for generating graphics. It offers an extended graphic library which can be used with sage cell servers.
[Error: Macro 'sagecell' doesn't exist]
The downside is that graphics have to be clicked separately. The link is given below the output cell. This might be acceptable if the graphics will be downloaded and used separate publications but not if the page where it resides is the publication. It is especially cumbersome in simulations.
If you want the the interaction immediatly visible, you have to learn sage. Sage programming language is mostly python as many programs as the one above run with both languages. But some exceptions exist, and those are especially prominent in graphics. Sage uses its own extended graphic library. It ofers a wide range of functionality but some feature as vlines in the example above is missing.
The same graphic as above in pure sage looks like:
[Error: Wrong macro arguments: "sagecell2 lang=\"sage\"" for macro 'sagecell' (maybe wrong macro tag syntax?)]
|