Multipage PDF
This is a demo of creating a pdf file with several pages, as well as adding metadata and annotations to pdf files.
import datetime
import matplotlib.pyplot as plt
import numpy as np
from matplotlib.backends.backend_pdf import PdfPages
# Create the PdfPages object to which we will save the pages:
# The with statement makes sure that the PdfPages object is closed properly at