3 ms·
Wow! You got a lot of responses! For me I think it's just the sheer time investment, personally. Spreadsheets give a very easy programming language, no compile
by crdrost 3y ago
Wow! You got a lot of responses!
For me I think it's just the sheer time investment, personally. Spreadsheets give a very easy programming language, no compiler, via Google sheets my phone can run it and my browser can run at and I can link it to someone... All great pros! But then it takes so long to be effective with them.
Give you an example of the last big app that I wrote for a spreadsheet: I have a 2-year-old, she was born a bit underweight with lip/tongue ties that gave her trouble latching, so we chose to do a hybrid breastfeeding/formula approach; we'd use bottles of pumped milk where we could, but if she was too frustrated to latch and we'd already used up the pumped milk we'd break out the baby formula.
But, we knew this was a risk: milk production is in response to demand, when it goes dry you activate more tissues that make more milk later. So I wanted to be able to answer my wife's questions of “is my milk supply getting stronger or drying up, what percentage of her diet was formula, etc.” and my own questions of “did I enter all of yesterday's stuff properly?”
So the spreadsheet is, a Google Form first dumps {
timestamp: date
what: enum('milk', 'formula')
from: enum('mama', 'enfamil', 'costco', 'bottle', 'freezer')
to: enum('waste', 'kid', 'bottle', 'freezer')
oz: decimal
when: nullable(date)
Note that this is basically an accounting journal, stuff is flowing from one account to another account, the time of transactions might be backdated via this optional "when" or might just be whenever the spreadsheet was filled out. This is immediately enhanced with three calculated properties,
rowID: number
effectiveDate: date
check: boolean
The consistency check will highlight the row red if I said something that was clearly nonsense and needs to be manually corrected (one way this isn't an accounting ledger!) like formula coming from the "mama" account or going into the "freezer".
These then get sorted on a following page and chunked by day. Another page allows me to track “how much milk is currently in bottles, how much formula is currently in bottles, how much milk is in the freezer," and an enhanced version on the next page shows me all of the account balances by date. Why these? So that I can answer “did I forget to input some of this milk/formula in my sleep addled state?”. A lot of this tracking was done by using my phone to just take a picture of an amount in a bottle and then piece together what had happened that day later. So it had to be checkable, “this says I have X ounces in the fridge, do I have that?”
The next page just has plain text, these are derivations of mathematical formulas, explanations of the modeling I wanted to do, thinking out loud so that the formula is showing up on the next page are not out of context when I later go to change them.
From the daily balances finally we get the models. Some ways I do this are to use a binomial distribution to smooth the data that I've got, with noisy data that can be a little bit easier than independent data points. I also tried some autoregression modeling to try and predict, with error bars, “today, tomorrow, the day after” for the binomial smoothing. I wanted to do this for three series which ended up being "total fluids kid has consumed, total milk pumped into either bottles or freezer bags, and formula: consumed milk ratio.” but this required a lot of iteration over different things that I might have wanted to try to graph before I could answer the questions that I really wanted to.
So I then like to plot line graphs where the data points are little X's, there are two dotted fit lines, one with the error from the model added, the other with the error from the model subtracted, so you get this kind of snake of error envelope that is just a running average in the middle but “opens its mouth” at the end, so that I am not telling a story that is not supported by the error bars given only the past couple days' data. If the entire snakehead is pointing up then yes, “your supply looks to be getting stronger this week!” but otherwise “it's still a bit early to say but here's what the story was three or four days ago.”
When I describe this to you it doesn't sound like a very complicated app, right? But writing it in a spreadsheet, which I needed so that I could input data or correct it from my phone at 3am, made this a very slow process, hours and hours were sunk into this tracking spreadsheets to get them where I needed them to be. And that's the big problem is that spreadsheets are kind of an “assembly language” level of solution where you have individual cells/registers that you have to track and update and coordinate, but the system doesn't connect everything together semantically so you have to express every single relationship yourself and then auto fill columns and whatever else to make it work.