MCPcopy Index your code
hub / github.com/dabeaz-course/python-mastery / read_csv_as_instances

Function read_csv_as_instances

Solutions/7_6/reader.py:37–42  ·  view source on GitHub ↗

Read CSV data into a list of instances

(filename, cls, *, headers=None)

Source from the content-addressed store, hash-verified

35 return csv_as_dicts(file, types, headers=headers)
36
37def read_csv_as_instances(filename, cls, *, headers=None):
38 '''
39 Read CSV data into a list of instances
40 '''
41 with open(filename) as file:
42 return csv_as_instances(file, cls, headers=headers)
43

Callers 1

stock.pyFile · 0.90

Calls 1

csv_as_instancesFunction · 0.70

Tested by

no test coverage detected