{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Customize parallels and meridians" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "execution": { "iopub.execute_input": "2025-01-13T11:30:31.832127Z", "iopub.status.busy": "2025-01-13T11:30:31.831507Z", "iopub.status.idle": "2025-01-13T11:30:32.364900Z", "shell.execute_reply": "2025-01-13T11:30:32.364411Z" } }, "outputs": [], "source": [ "%matplotlib inline\n", "# for figures in notebook\n", "\n", "# import & initialize epygram\n", "import epygram\n", "epygram.init_env()\n", "\n", "import os\n", "INPUTS_DIR = os.path.join('..', 'inputs')" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "execution": { "iopub.execute_input": "2025-01-13T11:30:32.367179Z", "iopub.status.busy": "2025-01-13T11:30:32.366954Z", "iopub.status.idle": "2025-01-13T11:30:32.502302Z", "shell.execute_reply": "2025-01-13T11:30:32.501663Z" } }, "outputs": [], "source": [ "r = epygram.open(os.path.join(INPUTS_DIR, 'analysis.full-arpege.tl149-c24.fa'), 'r')" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "execution": { "iopub.execute_input": "2025-01-13T11:30:32.504433Z", "iopub.status.busy": "2025-01-13T11:30:32.504226Z", "iopub.status.idle": "2025-01-13T11:30:32.578701Z", "shell.execute_reply": "2025-01-13T11:30:32.578214Z" } }, "outputs": [], "source": [ "f = r.readfield('SURFTEMPERATURE')" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "execution": { "iopub.execute_input": "2025-01-13T11:30:32.580777Z", "iopub.status.busy": "2025-01-13T11:30:32.580609Z", "iopub.status.idle": "2025-01-13T11:30:33.346664Z", "shell.execute_reply": "2025-01-13T11:30:33.346275Z" } }, "outputs": [], "source": [ "# No grid\n", "fig, ax = f.cartoplot(parallels=None, meridians=None)" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "execution": { "iopub.execute_input": "2025-01-13T11:30:33.349413Z", "iopub.status.busy": "2025-01-13T11:30:33.349207Z", "iopub.status.idle": "2025-01-13T11:30:33.868149Z", "shell.execute_reply": "2025-01-13T11:30:33.867655Z" } }, "outputs": [], "source": [ "# Customized\n", "fig, ax = f.cartoplot(parallels=[-66.56, -23.44, 0, 23.44, 66.56], meridians=20)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "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.10.12" } }, "nbformat": 4, "nbformat_minor": 2 }