Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In Python Find and the values of beta_0 and beta_1 that minimize ssr(y, x, beta_0, beta_1). Write a function minimize_ssr(y, x, beta_0_min, beta_0_max, beta_1_min, beta_1_max,

In Python Find and the values of beta_0 and beta_1 that minimize ssr(y, x, beta_0, beta_1). Write a function minimize_ssr(y, x, beta_0_min, beta_0_max, beta_1_min, beta_1_max, step)

A) Find values by evaluating ssr(y, x, beta_0, beta_1) over every combination of (beta_0,beta_1) in two list B) Create list beta_0_list and beta_1_list from ranges beta_0 = beta_0_min ,......., beta_0_max and beta_1 = beta_1_min ,......., beta_1_max, where the neighboring values of beta_0 and beta_1 are separated by distance step. C) Start with min_SSR = 999,999. Loop over the index numbers i and j for both list. D) For each pair of i and j extract the value beta_0_list[i]and beta_1_list[j] E) For each pair of i and j evaluate SSR, if lower than min_SSR record the new i_min= i and j_min=j and update the newest value of min_SSR. F) After the loops return [ beta_0[i_min], beta_1[j_min] ]

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Principles Programming And Performance

Authors: Patrick O'Neil, Elizabeth O'Neil

2nd Edition

1558605800, 978-1558605800

More Books

Students also viewed these Databases questions

Question

Which products should be restocked?

Answered: 1 week ago

Question

=+what information would you need about the compact disc industry?

Answered: 1 week ago