I am having difficulty parsing a line from an hdr file I have. When I print read (data) like in the code below the command window outputs the contents of the hdr file. However, when I try to parse out a line or a column , like the script below, it outputs nothing in the command window.
import numpy as np
import matplotlib.pyplot as plt
f = open('zz_ssmv11034tS__T0001TTNATS2012021505HP001.Hdr', 'r')
data = f.read()
print (data)
for line in f:
columns = line.split()
time = float(columns[2])
print (time)
f.close()