We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Artificial Intelligence
- Statistics and Machine Learning
- Correlation and Regression Lines - A Quick Recap #2
- Discussions
Correlation and Regression Lines - A Quick Recap #2
Correlation and Regression Lines - A Quick Recap #2
Sort by
recency
|
48 Discussions
|
Please Login in order to post a comment
The regression line suggests exam score increases by ~4.85 points for each additional study hour.
The fit looks good visually, and the correlation confirms strong linear association.
Would you like to try this on a specific dataset or should I explain how residuals or R² come into play? Betguru Login
Interesting problem! It's a great way to practice applying regression analysis with real data. Calculating the slope by hand gives good insight into how relationships between variables are analyzed. Thanks for sharing this! Cricbet99
Help !!
new to hackerRank , how to debug here ?? what's the expected input and output format ? This code runs perfect locally....
import numpy as np from sklearn.linear_model import LinearRegression
def return_cof(x,Y): x=np.array(x).reshape(-1, 1) y = np.array(Y).reshape(-1, 1) reg=LinearRegression().fit(x,Y) ans=reg.coef_ return round(ans[0],3)
a=[15,12,8,8,7,7,7,6,5,3] b=[10,25,17,11,13,17,20,13,9,15] ans=return_cof(a,b) print(ans)
Does anyone know why I am getting this error? Thank you
import numpy as np ModuleNotFoundError: No module named 'numpy'