ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Thu, 17 Jul 2014 19:41:52 +0200How to Run Entire Worksheet?https://ask.sagemath.org/question/23443/how-to-run-entire-worksheet/ Hello,
Now I have many cells of calculation in sagemath worksheet. I am looking for a way to run the entire worksheet at once, and generate result for printing. Any ideas? Thanks!Wed, 16 Jul 2014 22:40:09 +0200https://ask.sagemath.org/question/23443/how-to-run-entire-worksheet/Answer by slelievre for <p>Hello,</p>
<p>Now I have many cells of calculation in sagemath worksheet. I am looking for a way to run the entire worksheet at once, and generate result for printing. Any ideas? Thanks!</p>
https://ask.sagemath.org/question/23443/how-to-run-entire-worksheet/?answer=23446#post-id-23446I am assuming you are working with the Sage notebook.
<h1>Description of the Sage notebook</h1>
You can use the Sage notebook on a computer you are logged in to, by typing, in a terminal, `sage -notebook` or `sage -n` or just `sage` and then `notebook()`. You can also use it on some online Sage Notebook server.
In the Sage notebook, each worskheet has at the very top a header with, on the left:
Sage | The Sage Notebook
Version <version_number>
and, on the right, your username and 8 links:
<username> | Toggle | Home | Published | Log | Settings | Help | Report a Problem | Sign out
A second header row has, on the left, this text:
<worksheet_title>
last edited <date_of_last_edit by <username_of_last_edit>
and, on the right, these three buttons:
[ Save ] [ Save & quit ] [ Discard & quit ]
A third header row has, on the left, four menus and a checkbox:
[ File... ] [ Action... ] [ Data... ] [ sage ] [ ] Typeset
and, on the right, 7 buttons:
Print | Worksheet | Edit | Text | Revisions | Share | Publish
<h1>How to evaluate all cells and print</h1>
The item `Evaluate All` in the `Action...` drop-down menu (second drop-down menu out of the five that are in the third header row) does precisely what you want, ie, evaluate all the cells in your worksheet one after the other!
To print, you can either use the `Print` button (first of the 7 buttons on the right in the third header row), or the `Print` item in the `File...` drop-down menu, or the print capabilities of your browser, or screen captures. Compare the results and decide what you like best.
<h1>Could I instead work in a TeX document?</h1>
Yes! Use the SageTeX package for LaTeX. See [the tutorial](http://www.sagemath.org/doc/tutorial/sagetex.html) in the Sage documentation.
Ideal for producing documents with a mix of text, formulas, Sage code, and Sage output.Thu, 17 Jul 2014 07:03:38 +0200https://ask.sagemath.org/question/23443/how-to-run-entire-worksheet/?answer=23446#post-id-23446Comment by Rongcui Dong for <p>I am assuming you are working with the Sage notebook.</p>
<h1>Description of the Sage notebook</h1>
<p>You can use the Sage notebook on a computer you are logged in to, by typing, in a terminal, <code>sage -notebook</code> or <code>sage -n</code> or just <code>sage</code> and then <code>notebook()</code>. You can also use it on some online Sage Notebook server.</p>
<p>In the Sage notebook, each worskheet has at the very top a header with, on the left:</p>
<pre><code>Sage | The Sage Notebook
Version <version_number>
</code></pre>
<p>and, on the right, your username and 8 links:</p>
<pre><code><username> | Toggle | Home | Published | Log | Settings | Help | Report a Problem | Sign out
</code></pre>
<p>A second header row has, on the left, this text:</p>
<pre><code><worksheet_title>
last edited <date_of_last_edit by <username_of_last_edit>
</code></pre>
<p>and, on the right, these three buttons:</p>
<pre><code>[ Save ] [ Save & quit ] [ Discard & quit ]
</code></pre>
<p>A third header row has, on the left, four menus and a checkbox:</p>
<pre><code>[ File... ] [ Action... ] [ Data... ] [ sage ] [ ] Typeset
</code></pre>
<p>and, on the right, 7 buttons:</p>
<pre><code>Print | Worksheet | Edit | Text | Revisions | Share | Publish
</code></pre>
<h1>How to evaluate all cells and print</h1>
<p>The item <code>Evaluate All</code> in the <code>Action...</code> drop-down menu (second drop-down menu out of the five that are in the third header row) does precisely what you want, ie, evaluate all the cells in your worksheet one after the other!</p>
<p>To print, you can either use the <code>Print</code> button (first of the 7 buttons on the right in the third header row), or the <code>Print</code> item in the <code>File...</code> drop-down menu, or the print capabilities of your browser, or screen captures. Compare the results and decide what you like best.</p>
<h1>Could I instead work in a TeX document?</h1>
<p>Yes! Use the SageTeX package for LaTeX. See <a href="http://www.sagemath.org/doc/tutorial/sagetex.html">the tutorial</a> in the Sage documentation.</p>
<p>Ideal for producing documents with a mix of text, formulas, Sage code, and Sage output.</p>
https://ask.sagemath.org/question/23443/how-to-run-entire-worksheet/?comment=23461#post-id-23461Thank you! I will try this out.Thu, 17 Jul 2014 19:41:52 +0200https://ask.sagemath.org/question/23443/how-to-run-entire-worksheet/?comment=23461#post-id-23461