Explains the basic operation method and available shortcut keys for notebooks created with Jupyter Notebook.
The cells displayed in the notebook have two modes: command mode and edit mode.
Command mode is the mode used to perform operations on cells such as adding and deleting cells using shortcut keys. If you see a blue line on the left side of the cell, you are in command mode.
Edit mode is the mode used to enter a program in a cell. If you see a green line on the left side of the cell, you are in edit mode.
Use the following shortcut keys to switch between command mode and edit mode.
Enter: Switch from command mode to edit mode Esc: Switch from edit mode to command mode
When switching using the mouse, click the text box to enter edit mode, and click the left part of the text box to enter command mode.
To add a cell, press the shortcut key in command mode as follows.
A: Add a cell above the current cell B: Add cell below current cell
If you press the B key from the following state, the cell will be added immediately below and the cell will move to the cell where the focus has been added.
If you press the A key from the following state, the cell will be added immediately above and the cell will move to the cell where the focus has been added.
To add a cell from the menu, click the "Insert" menu. Click "Insert Cell Above" from the displayed menu to add a cell just above the current cell, and click "Insert Cell Below" to add a cell just below the current cell.
To delete a cell, press the shortcut key in command mode as follows. Press the D key twice in a row.
D D: Delete the current cell
If you press the D D key from the following states, the current cell will be deleted.
To delete a cell from the menu, click the "Edit" menu and then click "Delete Cells" from the displayed menu.
Recommended Posts