I am new to python and can use any help I can get. I am on a win7 machine and am using python 3.5 (anaconda)
I am trying to iterate through multiple CSV files (10k +) within a folder, checking for any value within that file that exceeds a predefined threshold.
I would like to build a dictionary, or list/tuple (basically whatever most resembles an sql table) using a sub-string of the filename as a unique identifier for a name field and have another column with total count of files that had values that exceeded the given threshold.
I don't expect any of you to do this for me as it is great practice, but I would appreciate any recommendations for modules that may make this a bit easier.
I've been able to check a file for a value but this is only about 10 minutes into this quest and I am not sure how I'd iterate through multiple files and build the table etc.. Thanks!
import numpy as np
path = 'C:\\path'
file = 'file.csv'
with open(path+file) as f:
my_data = np.genfromtxt(path+file, delimiter = ",")
for data in my_data:
if -1 in my_data:
print("it sure is")