Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@florisvb
Created May 2, 2018 01:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save florisvb/e7ca46cf64c82c5f13612dfa0d92888d to your computer and use it in GitHub Desktop.
Save florisvb/e7ca46cf64c82c5f13612dfa0d92888d to your computer and use it in GitHub Desktop.
Psuedo script for opening and plotting hdf5 data
import h5py
f = h5py.File(filename)
print f.keys()
data = f[keyname].value # choose a keyname from the list of keys
print data
a = data[name] # choose a name from the data dtype names
import matplotlib.pyplot as plt
fig = plt.figure()
ax = fig.add_subplot(111)
ax.plot(a)
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment