Optimal time to shower in Winter ?

The question occurred to me, I figured it was probably about 1pm, but as I had a shed load of data and wanted to have a play with pandas thought I’d do a quick python prog to find out.

Can of course do a lot of filtering, ordering, grouping and averaging with an SQL statement, but was interesting to discover pandas has an sql interface and a direct interface to matplotlib… Cool. In a few lines of python code and some tweaking get a nice graph.

click graph for more detailed view

I do not claim these temperatures are bang on but as an idea of how temperature fluctuates by hour is about right, i.e. big fluctuation in winter/spring more stable in late-summer/autumn but could be affected by missing data :

a) I think on an individual reading the sensor is at least 0.5c over due to self heating as I set compensation to zero and may be as much as 1c over.

b) I need to probably check if pandera can check for missing segments and readings out of kilter or do some similar checks using SQL and python on my dataset. I know on startup if a missing segment where powered down (battery run out) the IAQ/Gas readings go out of normality, but temperature, humidity, pressure are all stable on startup

c) doing an average temperature per hour per week would be interesting, but not enough years data to be useful. If had full 2 years data then probability missing segments strike in same place would be less, but weather varies eh! All about constant and consistent data!

d) readings also very influenced by being attached to a metal shed and shaded for a large portion of the day, but similar set of parameters to the bathroom.

Basically pandas does time sequence stuff nicely! And can use any assortment of strptime date formats to convert any timestamp format you may have… actually python has a cool auto date parsing routine that checks most of likely types. I have used a few over the years, possibly still a string representation best for keying and SQL LIKE lookups.

Leave a Reply