Smoothing Jupyter Startup

Within:

C:\Users\\.ipython\profile_default\startup

place whatever files you want executed with the following naming convention

00-global_imports.py
01-local_imports.py
02-global_magics.ipy

with contents like:

00-global_imports.py

#global imports
import matplotlib as mpl
mpl.use('agg')

import datetime          as dt
import matplotlib.cm     as cmap
import matplotlib.dates  as mdates
import matplotlib.pyplot as plt
import matplotlib.ticker as ticker
import numpy             as np
import os 
import re
import scipy             as sp
import scipy.interpolate as interp
import scipy.optimize    as opt
import scipy.special     as special
import spacepy.pycdf     as pycdf
import sys
02-global_magics.ipy

#magic happens
%load_ext autoreload
%autoreload 2
%matplotlib inline

Leave a Reply

Your email address will not be published. Required fields are marked *