Question: Could you help writing a user defined function for part B and a for / while loop for part C . B . Averaging for
Could you help writing a user defined function for part B and a forwhile loop for part C
B Averaging for Each Year Write a userdefined function that calculates the average Ocean
average Ocean and average atmospheric for a given year. The specification of the
function is as follows:
Inputs: the two data tables TableOne & TableTwo and the year a scalar
Outputs: Average Ocean pH Ocean CO and Atmospheric for the specified year scalars
Use logical indexing andor the find function, NOT loops or if statements.
C Using the function that you wrote in part B calculate the average Ocean Ocean and
Atmospheric CO for each year from to Store the results in a matrix with the
following format:
Column : year
Column : average Ocean
Column : average Ocean CO
Column : average Atmospheric
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
