Skip to content

Instantly share code, notes, and snippets.

View lkluft's full-sized avatar

Lukas Kluft lkluft

View GitHub Profile
@lkluft
lkluft / colorbar_for_lineplot.ipynb
Created August 18, 2016 09:28
Add colorbar to line plots.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lkluft
lkluft / create_divergent_cmap.ipynb
Created September 13, 2016 10:17
Create and register a divergent colormap.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lkluft
lkluft / multi_page_pdf.ipynb
Created November 15, 2016 13:59
Store plots on different pages in one single PDF.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lkluft
lkluft / tick_formatter.ipynb
Last active March 3, 2017 09:01
Change the way ticklabels are created.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lkluft
lkluft / plot_functions.ipynb
Last active March 3, 2017 07:47
Clean way to plot in different axes.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lkluft
lkluft / main.job
Created May 16, 2017 07:51
SLURM job dependency
#!/bin/bash
#SBATCH --job-name=main
#SBATCH --output=main-%j.out
#SBATCH --error=main-%j.err
#SBATCH --account=uni
#SBATCH --partition=uni-u237
#SBATCH --nodes=1-1
#SBATCH --ntasks=1
#SBATCH --cpus-per-task=1
@lkluft
lkluft / surf3d.py
Created May 17, 2017 12:42
3D surface plot with values
#!/usr/bin/env python3
"""3D surface (color map)
Demonstrates plotting a 3D surface colored with the coolwarm color map.
The surface is made opaque by using antialiased=False.
Also demonstrates using the LinearLocator and custom formatting for the
z axis tick labels.
"""
from mpl_toolkits.mplot3d import Axes3D
@lkluft
lkluft / finite_differences.ipynb
Last active May 23, 2017 15:22
Numerically solve differential equations.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lkluft
lkluft / command_line_arguments.ipynb
Created May 23, 2017 06:17
The argparse module makes it easy to write user-friendly command-line interfaces.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lkluft
lkluft / lotka_volterra.ipynb
Created May 23, 2017 06:19
Solution and visualisation of the Lotka–Volterra equations, also known as the predator–prey equations.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.