Processing | Excel | Matlab | EXAM – ECE 102

EXAM – ECE 102
Instructor: Peter Jamieson
– This is a take home exam. The work must be your own. Any common code will result in the exam being forwarded to administration for academic integrity violation. Do not show, give, or tell anyone else how you are solving the problems.
– Submit your zipped file.
– Please read all instructions carefully!
– The total for the exam is 100 marks.
– Submit your zip file with the exact details below
ZIP File:
Your zip file for answering the questions should have where XYOURUSERNAMEX is equal to your Miami username. Any additional changes I need to make will result in point deductions from the respective question:
– XYOURUSERNAMEX.xls or a link to a google spreadsheet for question 1
– XYOURUSERNAMEX/XYOURUSERNAMEX.pde a directory and in that directory a processing file for question 2
– MATLAB/ XYOURUSERNAMEX.m a directory called MATLAB with a matlab script for question 3
– ETHICS/ XYOURUSERNAMEX.doc or .txt a directory called ETHICS with a document describing your ethical thoughts

Questions 1 (20 marks)
Given the climate_data.xls (on canvas site under RESOURCES->EXAM) as your data set, pick two cities and do the following:
a) [10 marks] Calculate the average and standard deviation for the “precipitation” and “temperature” in a year.
b) [10 marks] Create a chart that shows the temperature per month for both cities with X-axis and Y-axis labels (where the X-axis is months {jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec} and the Y-axis is temperature)
Questions 2 (40 marks)
In processing, create a program that when you start it, it records where the mouse moves (X and Y coordinates) in the processing window for 15seconds (1 record per frame). Once the 15 seconds is up, the program will output how long the mouse was in each quadrant of the window. Also, record how many times the mouse was clicked and where those clicks happened.
a) [10 marks] Creating a program that records X Y for 15 seconds
b) [10 marks] Recording mouse location and mouse clicks
c) [5 marks] Outputting the percentage of time the mouse was in each quadrant
d) [5 marks] Outputting the number of clicks in each quadrant
e) [5 marks] For making graphic output of location in the processing window
f) [5 marks] Commented and well written code
Questions 3 (30 marks)
Solve the following:
In Matlab (.m file) called function donations (n), randomly create n data points representing donations from n different people between 500 and n*500 dollars. Next, find the
a) [5 marks] calculate and display geometric average donation
b) [5 marks] calculate and display the standard deviation of this average
c) [10 marks] calculate and display the average of the top 20 donors
d) [10 marks] make a bar graph for each donation ordered from least to greatest. Label the x and y axis

Questions 4 (10 marks)
Are there any ethical considerations to any of the above questions in terms of how they could be used for the good or bad of society? Maximum one page of writing.

This spot is for recording your marks

Out of