I need help with this problem? I seem to have the data arrays printing but it doesn’t come out correctly. I am using Python 3.0.
These are two data arrays, representing
#total time spent on assignments in a course weekly, and numeric grades of students.
#However, I have intentionally added error to the numbers.
#Using a random uniform distribution, add or subtract a value between
#0 and 4 to hours spent, and 0 to 10 to each numeric grade.
#Plot the regression line for your simulated data (one time only).
import warnings
warnings.filterwarnings(‘ignore’)
time_spent_in_course=[5, 7, 8, 10, 16, 5, 5, 7, 8, 20]
numeric_grade = [80, 85, 85, 90, 90, 90, 75, 75, 85, 75]
import random
random_hour = random.uniform(0,4)
print(‘Time spent will be subtracted by:’)
print(random_hour)