# Code and Variable Mode

Selecting the "code and variable" option under each block will take the selected block to code and variable mode.

<figure><img src="/files/EpLvVFpUZU3TrH8lon6k" alt=""><figcaption><p>Important Sections of code and variable mode</p></figcaption></figure>

## Elements of Code and Variable Mode

In code and variable mode, the user can access the input variables going into a block and the list of variables, plots, dataframes coming out of the block as outputs. There is an inbuilt viewer for dataframes (~~df.head()~~ 👋) and plots for quick access.

{% embed url="<https://files.gitbook.com/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FIQKNeqjEeOp9UwUcB9R9%2Fuploads%2FmvdhCTSbL8xX7OQ5oiDP%2FScreen%20Recording%202025-03-26%20at%201.39.08%E2%80%AFPM.mp4?alt=media&token=a1b291c6-02af-4b84-b8e6-fe1eec80771d>" %}
Input and output variables
{% endembed %}

As seen in the gif below, block\_a and block\_b are connected and you can use the output of block\_a in block\_b, but you can also use output from block\_c by attaching variables as shown below.

{% embed url="<https://files.gitbook.com/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FIQKNeqjEeOp9UwUcB9R9%2Fuploads%2F0b8Bt269wRQNk9x8zjZa%2FScreen%20Recording%202025-03-26%20at%201.44.58%E2%80%AFPM.mp4?alt=media&token=3dfb457b-b929-41c7-ae0e-943957d9c6fa>" %}
Attach variable
{% endembed %}

## Block Toggle

You can move to either previous or next block from within code and variable mode. You can refer the video below for the same.

{% embed url="<https://files.gitbook.com/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FIQKNeqjEeOp9UwUcB9R9%2Fuploads%2FhtJ4Yp4meLxqLiVyMeu6%2FView%20Toggle.mp4?alt=media&token=4b0453eb-0acf-4334-afcd-16c5625317c7>" %}
Block toggle
{% endembed %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.zerve.ai/guide/canvas-view/blocks-and-connections/code-and-variable-mode.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
