I guess the biggest news centered around Lowell this summer has been the Market Basket fiasco. A couple of weeks into the boycott, I thought I’d create a visual to contrast our spending at different markets in the past year. Naturally, I used Mathematica. Here is a version of the plot I posted on a Facebook group site related to Lowell:
Naturally, the plot labeled MRKT BSKT is our spending at Market Basket. The SHAW graph is actually a combination of our spending at Shaw’s and Hannaford’s. I think I stopped at Shaw’s around February and bought a few items, but other than that, spending there started at the same time as the boycott.
Instead of making this a one-time exercise, I decided to develop a function that would create other graphs like this one. My main summer project has been to rebuild the stairs at my son’s house in Chelmsford, adding a small deck. Out of convenience, my main spending on the project, which started in mid-July, has been at three locations. They are my local NH Home Depot (no sales tax!), where I’ve bought most of the smaller items I could fit into my Subaru, the Lowell Lowe’s, which is five minute from the project and where I’ve bought several last minute items I didn’t expect to need, and finally, Friend Lumber from whom I’ve had lumber delivered. Here is the spending plot at those locations for 2014, with another ~$100 spending to go at this point:
One more example, here is my coffee spending – this is flawed in that it is only the debit card spending, so a lot of my purchases at Einstein’s during the year are not included.
A&E is my local coffee roaster, and I definitely spend more there that anywhere else, even if I took into account cash sales. Also, I use the Starbucks app on my phone, which is why larger, less frequent purchases are recorded there.
If you’d like to try this with your spending, you can
download a copy of the Mathematica Package that creates these graphs. The package assumes you have a Bank of America debit card. You would download activity from your account and use the file path to that .csv file on your computer to specify the data file. With a bit of Mathematica expertise, it shouldn’t be hard to adapt the package to other banking systems.
try{for(var lastpassiter=0; lastpassiter < document.forms.length; lastpassiter++){ var lastpassf = document.forms[lastpassiter]; if(typeof(lastpassf.lpsubmitorig2)==”undefined”){ lastpassf.lpsubmitorig2 = lastpassf.submit; lastpass_f.submit = function(){ var form=this; var customEvent = document.createEvent(“Event”); customEvent.initEvent(“lpCustomEvent”, true, true); var d = document.getElementById(“hiddenlpsubmitdiv”); if (d) {for(var i = 0; i < document.forms.length; i++){ if(document.forms[i]==form){ d.innerText=i; } } d.dispatchEvent(customEvent); }form.lpsubmitorig2(); } } }}catch(e){}