Publications by Edgar Centeno
Assignment 2
Carefully explain the differences between the KNN classifier and KNN regression methods. These two methods are both non-parametric and utilize the nearest neighbor approach . Their difference mostly lies as to the type of problems they are used for. KNN classifier is used mainly for classification problems, those dealing with categorical(quantit...
6159 sym R (13618 sym/43 pcs) 3 img
Assignment 5
library(ISLR) ## Warning: package 'ISLR' was built under R version 4.0.3 library(glmnet) ## Warning: package 'glmnet' was built under R version 4.0.4 ## Loading required package: Matrix ## Loaded glmnet 4.1-1 library(pls) ## Warning: package 'pls' was built under R version 4.0.4 ## ## Attaching package: 'pls' ## The following object is masked f...
3572 sym R (9557 sym/32 pcs)
Document
library(ISLR) ## Warning: package 'ISLR' was built under R version 4.0.3 library(boot) library(MASS) We now review k-fold cross-validation. Explain how k-fold cross-validation is implemented. k-fold cross validation is implemented by randomly assigning the total amount of observations (n) into non-overlapping groups of an approximate size of ...
5816 sym R (6531 sym/54 pcs)
Assignment 3
This question should be answered using the Weekly data set, which is part of the ISLR package. This data is similar in nature to the Smarket data from this chapter’s lab, except that it contains 1, 089 weekly returns for 21 years, from the beginning of 1990 to the end of Produce some numerical and graphical summaries of the Weekly data. Do the...
3803 sym R (10037 sym/37 pcs) 3 img
Document
library(e1071) library(ISLR) ## Warning: package 'ISLR' was built under R version 4.0.3 library(caret) ## Warning: package 'caret' was built under R version 4.0.3 ## Loading required package: lattice ## Loading required package: ggplot2 We have seen that we can fit an SVM with a non-linear kernel in order to perform classification using a non-l...
3944 sym R (18052 sym/73 pcs) 26 img
Document
In this exercise, you will further analyze the Wage data set considered throughout this chapter. Perform polynomial regression to predict wage using age. Use cross-validation to select the optimal degree d for the polynomial. What degree was chosen, and how does this compare to the results of hypothesis testing using ANOVA? Make a plot of the re...
1262 sym R (8079 sym/23 pcs) 10 img
Document
library(ggplot2) library(ISLR) ## Warning: package 'ISLR' was built under R version 4.0.3 library(tree) ## Warning: package 'tree' was built under R version 4.0.3 library(dplyr) ## ## Attaching package: 'dplyr' ## The following objects are masked from 'package:stats': ## ## filter, lag ## The following objects are masked from 'package:b...
3429 sym R (11218 sym/75 pcs) 9 img