# Stata Kernel for Jupyter

Install Stata kernel to allow Jupyter users to create and run Stata files in Jupyter Notebooks:

```
pip install stata_kernel
python -m stata_kernel.install
```

Ensure that the stata\_kernel is installed correctly:

```
nano .stata_kernel.conf
```

Use CTRL+O then enter to overwrite the document and CTRL+X to exit.

{% hint style="info" %}
Make sure `stata_path` is pointing to the correct executable. *It can be different depending on your Stata version*.
{% endhint %}

![](/files/-MDGk37HUbE9HsqsgMCz)

Copy the configuration file to system configuration for all users:

```
cp .stata_kernel.conf /etc/stata_kernel.conf 
```


---

# 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-jupyter.davidjachochavez.org/stata/stata-kernel-for-jupyter.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.
