Skip to main content
Documentation

Notebooks

An interactive notebook mixes data, logic and visualizations to describe ideas and concepts.
This style of literate programming supports reproducible research and open access in data science.

Expansion

Notebooks open collapsed: the common entity UI components are hidden, which keeps the notebook readable.
Click the expansion icon to show them.

A notebook you write yourself opens for editing. The report of an analysis opens for reading instead and gets an Edit report control next to the expansion icon; see Analyses.

Sections

To add a section, click the plus icon at the bottom of the notebook or the insertion marker between two sections, and choose the section type in the menu.




These entity types can be sections of a notebook:

Section Description FDK API
Chapter Structuring unit within a notebook Chapter
Layout Column layout unit within a notebook Layout
Spacer Vertical spacing unit within a notebook Spacer
Contents Table of contents (TOC) Contents
Function Intelligent function to map the project graph Function
Table Table of structured data Table
Model Automated analysis model Model
Chart Graphical representation of data Chart
Text Textual output in a notebook Text
Image Two-dimensional image Image

Interdependencies

Sections may depend on each other. All sections are automatically refreshed after each function evaluation.

Structuring

Chapters structure a notebook, and a notebook with at least one chapter shows a table of contents.
Chapters can be nested, and sections can be reordered by drag and drop.

Layout

A layout section places sections side by side in columns.

Export & import

A notebook can leave the platform as a Diafunc bundle: a portable, human-readable .dfnb file (a ZIP whose members are JSON for structure and CSV for table data). Use it to version a notebook in git, share it, or move it between projects and clusters. A bundle is self-contained: exporting a notebook automatically includes the full closure of entities it references (chapters, tables, functions, models, charts and their data), so it re-imports anywhere with no dangling references.

From the Bundle menu in the Lab action bar, Export notebooks… lets you pick one or more notebooks and download the bundle (or queue a background job for large exports). Import bundle… uploads a .dfnb, previews its inventory, and then commits it into the current project under new ids, so a re-import never collides with existing content.

Table data round-trips through CSV by default, which keeps the bundle readable; choose the Parquet encoding when exact column typing matters. Per-entity version history is not included: a bundle captures the current state of each notebook.

Export & import from the CLI

The same bundles can be produced and consumed from the command line:

CommandDescription
diafunc notebook export <project> <notebookId…> --out file.dfnbExport notebooks to a bundle (add --data parquet for typed table data, --async to queue).
diafunc notebook import <project> file.dfnbImport a bundle (--preview to inspect first, --on-conflict copy|overwrite|skip).
diafunc notebook bundles <project>List bundle-export jobs for a project.

What next?