Python Study Group 1
Python Study Group 1
Problem:
You are running a process on a vacuum oven like the
one pictured in Figure 1. This process requires the
oven to be maintained at 200 C for 3 days. Any
deviation from this temperature will result in the
failure of your process.
?
After two attempts you see that your process is
continually failing. However, you are not sure if the
temperature of the oven is causing this. Therefore, you
set-up a temperature monitor that will record the
temperature in one-hour intervals for the entire three-
day process.
Set-up:
In order to solve this problem you must write a program in python that imports the data into a
NumPy array from the ‘tempdata.txt’ file, returns the daily average temperature along with its
standard deviation, and creates an alert if the 3 C threshold is crossed during any of the hours
of the process.
To do this you will need to utilize NumPy arrays for data storage, for loops to iterate through the
array, and if statements to determine if the threshold is met.
Helpful Hint:
Using NumPy you can read a text file into an array using the numpy.genfromtxt() function.
This function needs two arguments: the first argument is the path of the text file, and the second
is the delimiter of the text file.