Plotting dates on the y-axis of a contour map/ hovmoller

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
Report Content as Inappropriate

Plotting dates on the y-axis of a contour map/ hovmoller

This post has NOT been accepted by the mailing list yet.
Hello all,

So I ran into a snare when making a Hovmoller for a case study. I have everything done and colors picked out. But for the life of me cannot find a way to get the Y-axis to plot the dates provided in the data. Here is the script I have.

import numpy as np
import datetime
import matplotlib.pyplot as plt
import os
import pandas as pd

def cmap(cmap):
    cmap =

data = pd.read_excel('/Users/operator/Documents/Hovmoller_dewpt.xlsx')


time= (a[:,0])
lat= (a[:,1])
lon= (a[:,2])
BATA= (a[:,3])
BSPA= (a[:,4])
BUFF= (a[:,5])
CLIF= (a[:,6])
FAYE= (a[:,7])
HERK= (a[:,8])
JOHN= (a[:,9])
JORD= (a[:,10])
OPPE= (a[:,11])
WEST= (a[:,12])
timeZ= (a[:,13])


plt.contourf(b, np.arange(40,67), cmap=('jet'))


plt.title('Dewpoint Hovmoller for Mesonet Sites')

#timeZ contains the dates I want, and instead of having the number of rows as the y axis I want the dates there instead. Attached is the graphic I get as of now. Any thoughts or advice is much appreciated!

Thank you