HOME/Articles/

matplotlib example setup (snippet)

Article Outline

Python matplotlib example 'setup'

Modules used in program:

  • import cartopy.io.shapereader as shpreader
  • import cartopy.crs as ccrs
  • import matplotlib.animation as animation
  • import matplotlib as mpl
  • import matplotlib.pyplot as plt
  • import pandas as pd

python setup

Python matplotlib example: setup

'''Import Packages'''
# data wrangling:
import pandas as pd
from math import log, exp
from datetime import datetime as dt, timedelta

# data visualisation:
import matplotlib.pyplot as plt
import matplotlib as mpl
from matplotlib import colors
import matplotlib.animation as animation
import cartopy.crs as ccrs
import cartopy.io.shapereader as shpreader

# define the working directory:
root_dir = '/content/drive/My Drive/'