diff --git a/environment.yml b/environment.yml index cd286364d..b1238827f 100644 --- a/environment.yml +++ b/environment.yml @@ -23,6 +23,7 @@ dependencies: - jupyter_client # Infrastructure + - itables - myst-nb - nbsphinx - pre-commit diff --git a/ncl/ncl_index/ncl-index-table-demo.csv b/ncl/ncl_index/ncl-index-table-demo.csv new file mode 100644 index 000000000..03c750bbf --- /dev/null +++ b/ncl/ncl_index/ncl-index-table-demo.csv @@ -0,0 +1,4 @@ +NCL Function,Description,Python Equivalent,Notes +sin(), Computes the sine of numeric types, math.sin() or numpy.sin(), example notebook +cos(), Computes the cosine of numeric types, math.cos() or numpy.cos(), example notebook +tan(), Computes the tangent of numeric types, math.tan() or numpy.tan(), example notebook diff --git a/ncl/ncl_index/ncl_index.ipynb b/ncl/ncl_index/ncl_index.ipynb new file mode 100644 index 000000000..0d3ce9fd4 --- /dev/null +++ b/ncl/ncl_index/ncl_index.ipynb @@ -0,0 +1,97 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "id": "4a6382b1-e561-4402-ae72-58b2b96fa630", + "metadata": { + "editable": true, + "slideshow": { + "slide_type": "" + }, + "tags": [] + }, + "source": [ + "# NCL Index" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "id": "36aab5eb-87cf-46da-9a2f-68eda52f4154", + "metadata": { + "editable": true, + "slideshow": { + "slide_type": "" + }, + "tags": [ + "remove-input" + ] + }, + "outputs": [], + "source": [ + "import itables\n", + "import pandas as pd\n", + "\n", + "itables.init_notebook_mode(connected=True)" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "id": "0eec630a-1d88-4ef8-bb52-883fc6515371", + "metadata": { + "editable": true, + "slideshow": { + "slide_type": "" + }, + "tags": [ + "remove-input" + ] + }, + "outputs": [], + "source": [ + "df = pd.read_csv('ncl-index-table-demo.csv')" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "id": "b409366c-3989-4b13-9316-08d1077a067c", + "metadata": { + "editable": true, + "slideshow": { + "slide_type": "" + }, + "tags": [ + "remove-input", + "full-width" + ] + }, + "outputs": [], + "source": [ + "itables.show(df, allow_html=True)" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3 (ipykernel)", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.13.3" + } + }, + "nbformat": 4, + "nbformat_minor": 5 +} diff --git a/ncl/ncl_index/ncl_index.rst b/ncl/ncl_index/ncl_index.rst deleted file mode 100644 index 67893ad31..000000000 --- a/ncl/ncl_index/ncl_index.rst +++ /dev/null @@ -1,15 +0,0 @@ -.. _ncl_index: - -NCL Index -========= - -.. Link to temp file with alphabetized version of csv file (see conf.py) -.. csv-table:: - :file: ../../tmp/ncl-index-table.csv - :width: 100% - :header-rows: 1 - :widths: 20, 35, 35, 10 - - -.. note:: - For more information on how we verify these recommendations, see the :ref:`receipts`.