Questions tagged [notebooks]

Questions on Notebooks (*.nb, *.ma in earlier versions), structured interactive documents produced by Mathematica that can contain text, graphics, sound, calculations, typeset expressions, and user interface elements.

Filter by
Sorted by
Tagged with
1
vote
1answer
72 views

Notebook to run on batches of files

I have a notebook that Imports files from a folder and processes and stores outputs into another folder. It works well with small number of files, however, when there's a large number of input files,...
0
votes
0answers
53 views

how to append one notebook at the end of another

I developed and tested two pieces of a new program separately from older programs. For this it wasn't too bad to copy and paste old cells and test as I went. But now I have the two sizeable program ...
3
votes
1answer
132 views

An alternative to (%%…%) (k times) [closed]

Sometimes it may be useful to use (%%…%) (k times) to get the kth previous result in a notebook instead of setting a variable. However, if I want to get the 8th previous result, for example, I would ...
5
votes
1answer
294 views

How to export all graphics from a notebook?

The problem I have a notebook consisting of around 50 expressions like following: data = Table[i, {i, 10}]; ListPlot[data (*, some Plot options *)] I want to ...
9
votes
1answer
128 views

Notebook with version-dependent cells

I want to make a notebook with the following special feature: some of its cells show up only when the notebook is opened in for instance versions 11 and 12, but are hidden if the notebook is opened in ...
3
votes
2answers
130 views

Drawing line in notebook with Mathematica command

I have a for loop that makes plots iteratively, in between the plots, I would like to draw a line in the notebook. Is there a command that is the equivalent of doing this: https://reference.wolfram....
2
votes
1answer
103 views

Hiding an evaluated cell as the evaluation completes - Self-hiding

I use expressions to create "control panels" to set dynamic variables to control the evaluation of other expressions in a large notebook. For example: I would like the expressions that create these ...
27
votes
2answers
981 views

Using the Wolfram Language in a Commercial Product

Background I am currently consulting with a client that is using Mathematica to prototype a number of proprietary algorithms. Many man-hours of work have gone into the development of these algorithms ...
6
votes
4answers
337 views

How to search within notebooks on Windows 10?

I have a lot of notebooks scattered in my downloads, documents and desktop folder. I have all the required locations on Windows indexing options but if I look at Advanced Options and File Types and nb ...
1
vote
0answers
35 views

Using input in notebook TOC to Open at page 50 of a notebook

Already I have made a Table of Contents (TOC) notebook. In it are buttons which when pressed load very long notebooks, like say notebook ZZZ, which contains research notes. TOC works great. ...
0
votes
1answer
167 views

Turning computation in a notebook into a function

I have a piece of code that I'd like to turn into a function. I'm aware of modules and saw this post. The problem is that my code is quite long, containing all kinds of functions of the form ...
5
votes
0answers
59 views

How to force a desired numeration of equations in Book/Monograph StyleSheet?

I am writing a text in the MMA > Format > StyleSheet > Book > Monograph StyleSheet. I have a problem with the automatic numeration of "EquationNumbered" cells. ...
12
votes
1answer
502 views

How do I remove all comments in a Mathematica notebook?

Is there an option to delete every comment enclosed within (* *)s for a whole notebook? Or is it possible to do it with some string processing?
0
votes
0answers
151 views

Run only a part of a notebook

Is it possible to run only a part of a notebook? I have a long notebook which takes forever to evaluate, so I was wondering if it was possible to run only a couple of cells instead of the whole ...
8
votes
2answers
495 views

How to delete all messages in the message window programmatically?

By evaluating some Mathematica commands, I wish to get the equivalent effect as selecting Delete All Messages on the message window.
2
votes
2answers
250 views

How to detect when the evaluation queue is empty?

Mathematica provides $Post, whose value, if set, is applied to every output expression. In particular, if one sets ...
4
votes
1answer
498 views

Can a Mathematica notebook be programmed to work as a LaTeX editor? [duplicate]

A short example code will show that the answer to this question is yes. The example code (which I give in my answer) is for a simple LaTeX editor that is almost a drop-in replacement for TeXworks. ...
15
votes
2answers
1k views

Mathematica notebook opening off the screen

I have an issue with opening Mathematica notebook. I'm using Student version of Mathematica 12.0 on Windows 10. When I initiate the Mathematica or create a new document from the start page, it opens ...
3
votes
0answers
78 views

Auto-completion for Python commands in console of Mathematica notebooks [closed]

A great feature introduced in Mathematica v11.3 is the embedded external language cell: https://www.wolfram.com/language/12/external-system-integration/evaluate-python-in-a-notebook.html?product=...
0
votes
0answers
53 views

Running a complex notebook from a different master notebook?

I am trying to use the Dynamo notebook (https://www.ssc.wisc.edu/~whs/dynamo/dynamo_3S_v1.4.1.nb) in a loop over parameters. Basically, this software takes one matrix as input, solves ODEs and some ...
2
votes
1answer
98 views

Open, Evaluate and Close notebooks sequentially

I wanna Open, Evaluate and Close notebooks sequentially. Code from question here ...
1
vote
0answers
38 views

Controlling the baseline position of a fraction numerator in a notebook style?

I'm using a built-in Notebook style "Equation" from the "Book/Textbook.nb" stylesheet. When entering fractions, the space between the bottom of the text in the numerator and the fraction line is too ...
4
votes
3answers
474 views

How do pure functions differ from functions defined with SetDelayed?

Why is it that f[{{a_, b_}, {c_, d_}}] := (a z + b)/(c z + d) will return (2 + z)/(4 + 3 z) on evaluating ...
5
votes
0answers
380 views

How to generate a table of contents?

This answer is several years old and while the code still works I was wondering if there was any update from the community or Wolfram. The online references still point to AuthorTools which seems to ...
2
votes
1answer
38 views

How to apply AlphabeticSort to a code cell?

I've got a single code cell in a notebook with lots of Usage messages in no particular order. I'd like to alphabetize them, but doing it manually would be a ...
0
votes
2answers
129 views

How does one use option CellGroupingRules?

It seems that Manual Cell Grouping is broken in 12.0.0.0 (at least in Linux). If one pastes a cell, then any cell bracketing gets "chopped" at the paste position. This bug affects a large project of ...
5
votes
2answers
226 views

How to execute this code on startup?

Every time I open a new notebook I have to manually evaluate this code in that notebook. In order order to stop my cursor moving to a new cell. How would I automate this? I would love this ...
7
votes
1answer
94 views

New input cell style with a custom evaluator

I'm interested to implement a custom input style which would appear (mostly?) like a normal "Input" Cell, but which would ...
2
votes
2answers
144 views

Expand/collapse option for Toolbar

When creating a docked cell, the toolbar stays forever visible and somewhat "eats up" space. Since I do not use the different buttons all the time, is there a way to make the toolbar expand/collapse?
5
votes
1answer
1k views

How to use Mathematica in AWS cloud?

I have a free account in AWS cloud for 1 year for $750$ hours. How to run Mathematica in AWS cloud? And is Mathematica chargeable in AWS cloud?
0
votes
1answer
124 views

Automatic indentation of text and equations depending on Style

I have a rule when writing text and equations. Starting from the Section environment, each text/equation that sits inside Section...
0
votes
0answers
43 views

Saving remembered function when closing down notebook [duplicate]

I have functions defined to remember their values f[x_]:=f[x] I would like to be able to close a notebook without losing the computed values, what is the ...
9
votes
1answer
99 views

What are the conseqences of setting TrackCellChangeTimes to False? How are CellChangeTimes useful?

I know there are discussions on this site about version control, etc. And it appears that CellChangeTimes are used for this purpose, but how? As an individual ...
3
votes
1answer
56 views

Using an image as a CellDingbat

I'm writing code that generates a report notebook using a defined style. I would like to display an image (a logo) in the title cell along with the title itself. How can this be done? Example: ...
1
vote
1answer
79 views

How to hide and show part of a notebook with a button?

I need to show the user a part of a notebook only if he clicks on a button (or on a checkbox). For example, the user can proceed only if he answers a question correctly in the notebook! Hope to be ...
2
votes
2answers
104 views

Export in slave notebook

I have a very complicated analysis running on a notebook named Called_notebook.nb which depends on two parameters. To automate the process, I call this notebook in a loop from a master notebook, like ...
1
vote
0answers
49 views

Keep notebook running in cloud?

If I have a Wolfram Cloud account, is there some way to keep a notebook running when I'm offline, e.g. TMUX? Leaving long-running computations to keep running in the cloud when I close my laptop would ...
4
votes
1answer
238 views

Cell Bracket Clarification

I am running a very simple program that uses NotebookEvaluate to evaluate an open notebook that only has the context of saving and closing, and while it completes that task, the program gets stuck in ...
3
votes
1answer
63 views

How can I resolve the entire set of style options for a notebook?

Given a NotebookObject I'd like to know what settings all of its Cells have. This could be useful if I needed to distribute my ...
6
votes
2answers
112 views

Store Dynamic-accessible hidden metadata in a cell

Is there a way to store metadata in a cell in such a way that it can be accessed with Dynamic? Think of e.g. how ExternalLanguage cells work. We can select whether ...
1
vote
1answer
164 views

Q: How to manage notebook crashes, "In a previous session", and memory consumption?

I worked in a notebook. Something went wrong. I do not know what or why. The notebook did not react anymore and closed. After it, I try to open the same notebook. Then the next text appears: "The ...
0
votes
1answer
32 views

How to collapse a cell group behind its 2nd cell with same functionality as WholeCellGroupOpener

Given a cell group containing two subcells... If you double click the bracket of the first cell, you collapse the group behind the first cell in that group. If, instead, you double click on the ...
1
vote
0answers
60 views

Floating Notebook

I want to make notebooks that float above other windows. The expression below creates a Notebook that floats above other Notebooks, but not above other windows (documents, etc.). Can it be done? <...
6
votes
2answers
101 views

How can I set the title of a notebook to the notebook filename, and keep it in sync automatically?

I usually use descriptive filenames for my notebooks, and then find myself manually copying that filename into a "Title" style top-level section in the notebook. I would like this to be automatic, or ...
8
votes
1answer
258 views

Programmatically creating a notebook containing plots for PDF export

In order to save computation results, I want to programmatically create some MMA notebooks and export them as PDF files. It works fine for text: ...
5
votes
1answer
154 views

All the group formatting available in Mathematica

I was wondering how many pre-defined group formatting style there is in Mathematica. From Format -> Style, one see that we can go from ...
2
votes
1answer
76 views

Update timestamp when saving [closed]

I re-worked a bit the solution for creating a timestamp in a previous post ...
4
votes
3answers
139 views

Redirecting CellPrint output

How can I make g[]; or h[]; print the same output as f[];? I am trying to capture the ...
1
vote
0answers
91 views

Generate a Notebook automatically [closed]

Good evening, I am interested in creating a Notebook with specific instructions in an automatic fashion using, say, Python. For example, I would like to generate the file NewNote.nb (a genuine ...
4
votes
0answers
110 views

Capture invisible notebook image

Is there anyway to grab an image of a notebook without it visibly opening? CurrentNotebookImage[nb] seems to force the notebook nb to become visible.

1
3 4
5
6 7
23