<jupyter_start><jupyter_text>Define the function for reading a file!<jupyter_code>def read_csv(file_name):
                f=open(file_name,'r')
                file=f.read()
                split_file=file.split("\n")
                string_list=split_file[1:len(split_file)]
                final_list=[]
                for i in string_list:
                    int_fields=[]
                    string_fields=i.split(",")
                    for j in string_fields:
                        int_fields.append(int(j))
                    final_list.append(int_fields)
                return(final_list)
cdc_list=read_csv("US_births_1994-2003_CDC_NCHS.csv")
print(cdc_list[0:10])<jupyter_output>[[1994, 1, 1, 6, 8096], [1994, 1, 2, 7, 7772], [1994, 1, 3, 1, 10142], [1994, 1, 4, 2, 11248], [1994, 1, 5, 3, 11053], [1994, 1, 6, 4, 11406], [1994, 1, 7, 5, 11251], [1994, 1, 8, 6, 8653], [1994, 1, 9, 7, 7910], [1994, 1, 10, 1, 10498]]<jupyter_text>Create a function to calculate the number of births per month!<jupyter_code>def month_births(mb):
    births_per_month={}
    for value in mb:
        month=value[1]
        births=value[4]
        if month in births_per_month:
            births_per_month[month]=births_per_month[month]+births
        else:
            births_per_month[month]=births
    return(births_per_month)
cdc_month_births=month_births(cdc_list)
print(cdc_month_births)
def dow_births(db):
    births_per_day_week={}
    for value in db:
        day=value[3]
        births=value[4]
        if day in births_per_day_week:
            births_per_day_week[day]=births_per_day_week[day]+births
        else:
            births_per_day_week[day]=births
    return(births_per_day_week)
cdc_day_births=dow_births(cdc_list)
print(cdc_month_births)

def calc_counts(data,column):
    births_per_column={}
    for value in data:
        day=value[column]
        births=value[4]
        if day in births_per_column:
            births_per_column[day]=births_per_column[day]+births
        else:
            births_per_column[day]=births
    return(births_per_column)
cdc_year_births.
cdc_month_births
cdc_dom_births<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.11214087117701575, 'fraction_numerical': 0.06209453197405004, 'mean_word_length': 2.7613240418118465, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '286571', 'license': 'MIT', 'n_tokens_mistral': 931, 'n_tokens_neox': 785, 'n_words': 144, 'path': 'Functions.ipynb', 'repo_name': 'SATHVIKRAJU/Dataquest-Data-Science-', 'size': '2158'}