Question: Write the function calculate _ column _ average that takes 2 arguments: csv _ file: which is the name of the csv _ file that
Write the function calculatecolumnaverage that takes arguments:
csvfile: which is the name of the csvfile that is to be read
columnno: which is the number of the data column that we want to calculate the average for.
For example, if we have the following values in a csv file:
The average for column is
The average for column is
The average for column is
Instructions:
Remember, in CSV files, the values in columns are separated by commas.
You only need to calculate the average for a specific column
Moodle will test the function, you only need to write it
You are free to use python functions or loops to calculate the average
Answer: penalty regime:
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
