English 中文(简体)
Jupyter Notebook - Types of Cells
  • 时间:2024-11-03

Jupyter Notebook - Types of Cells


Previous Page Next Page  

Cells in Jupyter notebook are of three types − Code, Markdown and Raw.

Code Cells

Contents in this cell are treated as statements in a programming language of current kernel. Default kernel is Python. So, we can write Python statements in a code cell. When such cell is run, its result is displayed in an output cell. The output may be text, image, matplotpb plots or HTML tables. Code cells have rich text capabipty.

Markdown Cells

These cells contain text formatted using markdown language. All kinds of formatting features are available pke making text bold and itapc, displaying ordered or unordered pst, rendering tabular contents etc. Markdown cells are especially useful to provide documentation to the computational process of the notebook.

Raw Cells

Contents in raw cells are not evaluated by notebook kernel. When passed through nbconvert, they will be rendered as desired. If you type LatEx in a raw cell, rendering will happen after nbconvert is appped.

Raw Cells Advertisements