Skip to content

tools that I've developed over time that form a part of my daily workflow built primarily around xarray. Thought good to share. Won't be making docs for now

License

Notifications You must be signed in to change notification settings

lukegre/all_my_code

Repository files navigation

all_my_code

tools that I've developed over time that form a part of my daily workflow. Thought good to share. Note that I do not test my code, I do not verify the results. So please treat with caution. Feel free to drop issues and suggest changes. No guarantee that I'll make the changes though.

Installation

To get the latest version:

pip install git+https://github.com/lukegre/all_my_code/

Usage

Just a few examples of functions that might be useful. This is not a complete list. The functions themselves are quite well documented.

WARNING: these examples are out of date

import all_my_code as amc  # will import xarray methods/accessors too
from cartopy import crs, feature
from matplotlib import pyplot as plt

xda = xr.open_dataarray('path_to_demo_data.nc')

# Time series stats #############
xda.time_series.climatology(tile=True)
xda.time_series.detrend(dim='time', deg=2)
xda.time_series.deseasonalise()

# PLOTTING ############
# maps with xarray
img = xda.isel(time=0).map()
img.colorbar.set_label('some label')

About

tools that I've developed over time that form a part of my daily workflow built primarily around xarray. Thought good to share. Won't be making docs for now

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages