I am analyzing some data. I got my for loop to print in array format but i wanted to print the results back in a data frame format as i am working with data frames.
import itertools
for time, flight in itertools.izip(flight_data["AirTime"], flight_data["UniqueCarrier"]):
if time > 300:
print (time, flight)
Outputs:(340, AA)
However, I want the output to return back in a dataframe format. Please assist thanks