Linear Regression

Q1)What does “random_state” argument do in make_regression()?

Also If coef is True, the coefficients of the underlying linear model are returned then what is its use here?

Q2)When we write,y) we actually set the value of m and c in y=mx+c and then by substituting Xgrid in our equation we get ypgrid via ypgrid = lr.predict(Xgrid) ! Is this notion correct?

Q3)What does this “lr_s.score(Xsample, ysample)” predict in
lr_s = LinearRegression().fit(Xsample, ysample)
r2_score(ysample, lr_s.predict(Xsample)), lr_s.score(Xsample, ysample)

random_state is a seed number for the random number generator.
Whatever random number you generate using a code needs a seed number. Usually people take current time as the seed but you can also give a specific seed.