Dataset 2
data2 <- read_excel("Dataset 1 dan 2 Regnon.xlsx",
sheet = "Dataset 2")
head(data2)
## # A tibble: 6 × 7
## X1 X2 X3 X4 X5 X6 Y
## <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
## 1 12.1 34.0 8.5 2.22 64.8 40.2 73.8
## 2 12.4 44.2 10.1 2.2 68.6 32.9 76.9
## 3 13.4 38.7 8.99 1.68 69.1 29.7 77.2
## 4 14.4 26.3 10.0 2.16 69.2 23.6 69.1
## 5 17.9 23.4 10.3 1.46 68.3 33.4 78.3
## 6 13.4 10.1 10.9 1.38 70.1 30.1 84.7
3a. Scatter Plot X1 terhadap Y
ggplot(data2, aes(x = X1, y = Y)) +
geom_point(alpha = 0.6) +
geom_smooth(method = "lm", se = FALSE) +
labs(
title = "Scatter Plot X1 terhadap Y - Dataset 2",
x = "X1",
y = "Y"
) +
theme_minimal()
## `geom_smooth()` using formula = 'y ~ x'

3b. Scatter Plot X2 terhadap Y
ggplot(data2, aes(x = X2, y = Y)) +
geom_point(alpha = 0.6) +
geom_smooth(method = "lm", se = FALSE) +
labs(
title = "Scatter Plot X2 terhadap Y - Dataset 2",
x = "X2",
y = "Y"
) +
theme_minimal()
## `geom_smooth()` using formula = 'y ~ x'

3c. Scatter Plot X3 terhadap Y
ggplot(data2, aes(x = X3, y = Y)) +
geom_point(alpha = 0.6) +
geom_smooth(method = "lm", se = FALSE) +
labs(
title = "Scatter Plot X3 terhadap Y - Dataset 2",
x = "X3",
y = "Y"
) +
theme_minimal()
## `geom_smooth()` using formula = 'y ~ x'

3d. Scatter Plot X4 terhadap Y
ggplot(data2, aes(x = X4, y = Y)) +
geom_point(alpha = 0.6) +
geom_smooth(method = "lm", se = FALSE) +
labs(
title = "Scatter Plot X4 terhadap Y - Dataset 2",
x = "X4",
y = "Y"
) +
theme_minimal()
## `geom_smooth()` using formula = 'y ~ x'

3e. Scatter Plot X5 terhadap Y
ggplot(data2, aes(x = X5, y = Y)) +
geom_point(alpha = 0.6) +
geom_smooth(method = "lm", se = FALSE) +
labs(
title = "Scatter Plot X5 terhadap Y - Dataset 2",
x = "X5",
y = "Y"
) +
theme_minimal()
## `geom_smooth()` using formula = 'y ~ x'

3f. Scatter Plot X6 terhadap Y
ggplot(data2, aes(x = X6, y = Y)) +
geom_point(alpha = 0.6) +
geom_smooth(method = "lm", se = FALSE) +
labs(
title = "Scatter Plot X6 terhadap Y - Dataset 2",
x = "X6",
y = "Y"
) +
theme_minimal()
## `geom_smooth()` using formula = 'y ~ x'
