You are here

Week 4: Proving words of wisdom (Never assume... )

This week was mostly tying up loose ends of the code.  I wrote the measurement placement subroutine and added it to the main program, and tested it using full runs of data.  Those runs are about 200 files each, so they took a while to process. 
I was semi-pleased with the results.  For every batch of 200 files, it misplaced about 2-3 measurements.  That was mostly because I was not aware that kind of data could happen and had not written code to process it.  It also identified completly bad data quite well.   I plan to debug the code, add more processing cases, and a bad data flagging system next week. 

Results:

Original Measurement Placement Program:

New Measurement Placement Program:


The new program find the areas with relatively flat slopes and then places the measurements there instead of assuming they will happen at a certain time.  The original program only works for ideal cases, where the factors relating to timing (such as flow rate and purge time) are assumed to be exactly the same. The new program, however can handle shifts or unexpected trends in the data.  The demise of the old program gives creedence to the journalism addage: 

"Never assume.  It makes an ass out of u and me."