<commit_before>import os
import sendgrid
from sendgrid.helpers.mail import * # source of Email, Content, Mail, etc.

from pandas_datareader import data
from datetime import date, timedelta

#Stock data for Apple, Amazon, Activision Blizzard, Hologic Inc, Ligand Pharmaceuticals Inc, Microsoft, Ferrari, <NAME>, Tesla, Vivint Solar Inc

symbols = ['AAPL', 'AMZN', 'ATVI', 'HOLX', 'LGND', 'MSFT', 'RACE', 'TROW', 'TSLA', 'VSLR']
data_source = 'google'
start = str(date.today() - timedelta(days=2))
end = str(date.today())

response = data.DataReader(symbols, data_source, start, end)

daily_closing_prices = response.ix["Close"]<commit_msg>Account for day of week<commit_after># for email functionality, credit @s2t2
import os
import sendgrid
from sendgrid.helpers.mail import * # source of Email, Content, Mail, etc.

# for day of week
import datetime

# to query Google stock data
from pandas_datareader import data
from datetime import date, timedelta

#Stock data for Apple, Amazon, Activision Blizzard, Hologic Inc, Ligand Pharmaceuticals Inc, Microsoft, Ferrari, <NAME>, Tesla, Vivint Solar Inc
symbols = ['AAPL', 'AMZN', 'ATVI', 'HOLX', 'LGND', 'MSFT', 'RACE', 'TROW', 'TSLA', 'VSLR']
data_source = 'google'

day_of_week = datetime.datetime.today().weekday()
# print(day_of_week) tested day of week functionality working

monday = [0]
other_weekdays = [1,2,3,4]

if day_of_week in monday:
    start = str(date.today() - timedelta(days=3))
    end = str(date.today())

elif day_of_week in other_weekdays:
    start = str(date.today() - timedelta(days=1))
    end = str(date.today())

response = data.DataReader(symbols, data_source, start, end)

daily_closing_prices = response.ix["Close"]
{'fraction_non_alphanumeric': 0.12935617247489664, 'fraction_numerical': 0.005906674542232723, 'mean_word_length': 5.591439688715953, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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}}
{'dir': 'git-commits-cleaned', 'id': '6469932', 'n_tokens_mistral': 601, 'n_tokens_neox': 564, 'n_words': 178}