From fa3d923eb28cc4d7cbc1eceb79cc88d8c34b5ca9 Mon Sep 17 00:00:00 2001 From: "xuanyi.wang" Date: Mon, 22 May 2023 20:40:36 +0200 Subject: [PATCH] Update page 'Questions concerning R language' --- Questions concerning R language.md | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Questions concerning R language.md b/Questions concerning R language.md index 76e05ed..5bba07e 100644 --- a/Questions concerning R language.md +++ b/Questions concerning R language.md @@ -1,14 +1,14 @@ ***Applied Question*** This problem involves the `OJ` data set which is part of the `ISLR` package. -> i. Create a training set containing a random sample of 800 observations, and a test set containing the remaining observations. -> ii. Fit a support vector classifier to the training data using `cost=0.01`, with `Purchase` as the response and the other variables as predictors. Use the `summary()` function to produce summary statistics, and describe the results obtained. -> iii. What are the training and test error rates? -> iv. Use the `tune()` function to select an optimal cost. Consider values in the range 0.01 to 10. -> v. Compute the training and test error rates using this new value for `cost`. -> vi. Repeat parts (ii) through (v) using a support vector machine with a radial kernel. Use the default value for `gamma`. -> vii. Repeat parts (ii) through (v) using a support vector machine with a polynomial kernel. Set `degree=2`. -> viii. Overall, which approach seems to give the best results on this data? +* i. Create a training set containing a random sample of 800 observations, and a test set containing the remaining observations. +* ii. Fit a support vector classifier to the training data using `cost=0.01`, with `Purchase` as the response and the other variables as predictors. Use the `summary()` function to produce summary statistics, and describe the results obtained. +* iii. What are the training and test error rates? +* iv. Use the `tune()` function to select an optimal cost. Consider values in the range 0.01 to 10. +* v. Compute the training and test error rates using this new value for `cost`. +* vi. Repeat parts (ii) through (v) using a support vector machine with a radial kernel. Use the default value for `gamma`. +* vii. Repeat parts (ii) through (v) using a support vector machine with a polynomial kernel. Set `degree=2`. +* viii. Overall, which approach seems to give the best results on this data? ***Conceptual Question***