Looking for verified NPTEL assignment answers for Week 2 of Introduction to Machine Learning? Below are all the correct responses along with brief explanations to help you better understand the underlying concepts.


1. In a linear regression model y = θ₀ + θ₁x₁ + θ₂x₂ + … + θₚxₚ, what is the purpose of adding an intercept term (θ₀)?

Options:
a) To increase the model’s complexity
b) To account for the effect of independent variables
c) To adjust for the baseline level of the dependent variable when all predictors are zero
d) To ensure the coefficients of the model are unbiased

Answer:✅ c
Explanation:
The intercept (θ₀) allows the regression model to fit data where the expected value of y is not zero when all x values are zero.


2. Which of the following is true about the cost function (objective function) used in linear regression?

Options:
a) It is non-convex
b) It is always minimized at θ = 0
c) It measures the sum of squared differences between predicted and actual values
d) It assumes the dependent variable is categorical

Answer:✅ c
Explanation:
The cost function in linear regression calculates the Sum of Squared Errors (SSE), which is minimized during training.


3. Which of these would most likely indicate that Lasso regression is a better choice than Ridge regression?

Options:
a) All features are equally important
b) Features are highly correlated
c) Most features have small but non-zero impact
d) Only a few features are truly relevant

Answer:✅ d
Explanation:
Lasso regression performs feature selection by shrinking some coefficients exactly to zero, making it ideal when only a few predictors matter.


📚Want Full NPTEL Assignment Support?
If you’re looking for expert-curated solutions with explanations, updated before deadlines,
👉 Click here to visit Answer GPT – your trusted learning partner.


4. Which of the following conditions must hold for the least squares estimator in linear regression to be unbiased?

Options:
a) The independent variables must be normally distributed
b) The relationship between predictors and the response must be non-linear
c) The errors must have a mean of zero
d) The sample size must be larger than the number of predictors

Answer:✅ c
Explanation:
To ensure unbiased estimators in OLS, one of the Gauss-Markov assumptions is that the error terms must have a mean of zero.


5. When performing linear regression, which of the following is most likely to cause overfitting?

Options:
a) Adding too many regularization terms
b) Including irrelevant predictors in the model
c) Increasing the sample size
d) Using a smaller design matrix

Answer:✅ b
Explanation:
Including irrelevant variables increases the model complexity and can lead to overfitting the training data.


6. You have trained a complex regression model on a dataset. To reduce its complexity, you decide to apply Ridge regression, using a regularization parameter λ. How does the relationship between bias and variance change as λ becomes very large?

Options:
a) bias is low, variance is low
b) bias is low, variance is high
c) bias is high, variance is low
d) bias is high, variance is high

Answer:✅ c
Explanation:
As λ increases, Ridge regression adds more penalty to weights, reducing variance but increasing bias.


7. Given a training dataset of 10,000 instances, with each input instance having 12 dimensions and each output instance having 3 dimensions, the dimensions of the design matrix used in applying linear regression to this data is

Options:
a) 10000 × 12
b) 10003 × 12
c) 10000 × 13
d) 10000 × 15

Answer:✅ c
Explanation:
We add a column of 1s for the intercept, so the matrix becomes 10000 × (12 + 1) = 10000 × 13.


8. The linear regression model y = a₀ + a₁x₁ + … + aₚxₚ is to be fitted to a set of N training data points. Which equation holds true for minimizing sum squared error?

Options:
a) XᵀX = XY
b) Xθ = XᵀY
c) XᵀXθ = Y
d) XᵀXθ = XᵀY

Answer:✅ d
Explanation:
This is the normal equation used to find the optimal solution in linear regression.


9. Which scenario is most appropriate for using Partial Least Squares (PLS) regression instead of ordinary least squares (OLS)?

Options:
a) Uncorrelated predictors and more samples
b) Categorical response and non-linear predictors
c) Multicollinearity or more predictors than samples
d) Interpretability is the priority over accuracy

Answer:✅ c
Explanation:
PLS is suitable when predictors are highly correlated or number of predictors > number of observations.


10. Consider forward selection, backward selection, and best subset selection. Which of the following is true?

Options:
a) Best subset selection can be computationally more expensive than forward selection
b) Forward and backward selection always lead to the same result
c) Best subset selection is computationally less expensive than backward selection
d) Best subset and forward selection are equally expensive
e) Both b and d

Answer:✅a
Explanation:
Best subset selection checks all combinations of predictors and is therefore more computationally expensive.


Conclusion
These were the accurate and concise solutions for Week 2 of Introduction to Machine Learning NPTEL Assignment. We hope this helped you understand the concepts and logic behind each answer. For solutions to all weeks and all NPTEL subjects:

👉 Visit Answer GPT – Introduction to Machine Learning Week 2 for more.