We will run an out-of-sample experiment to see how well cross-validated lasso pe

Economics

comment No Comments

By admin

Important - Read this before proceeding

These instructions reflect a task our writers previously completed for another student. Should you require assistance with the same assignment, please submit your homework details to our writers’ platform. This will ensure you receive an original paper, you can submit as your own. For further guidance, visit our ‘How It Works’ page.

We will run an out-of-sample experiment to see how well cross-validated
lasso performs. First, draw a random sample of size n = 8, 000 from the original 10, 000
observations, without replacement. We will refer to these observations X1, . . . , Xn and
Y1, . . . , Yn as the “estimation” sample. We will refer to the remaining m = 2, 000
observations Xn+1, . . . , Xn+m and Yn+1, . . . , Yn+m as the “holdout” sample. Question 1.
Run 5-fold cross-validated lasso of log(yspend) on xweb on the estimation sample of n = 8, 000 observations. Report a plot of the out-of-sample
cross validation error as a function of λ (you can use the plot command on the
cv.gamlr object as in the lecture notes).
Please using R software and provide the related code file

get this assignment from a professional tutor. 100% original paper.

learn how

Leave a Comment