1.LIBRARY
library(tidyverse)
## ── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
## ✔ dplyr 1.2.0 ✔ readr 2.2.0
## ✔ forcats 1.0.1 ✔ stringr 1.6.0
## ✔ ggplot2 4.0.2 ✔ tibble 3.3.1
## ✔ lubridate 1.9.5 ✔ tidyr 1.3.2
## ✔ purrr 1.2.1
## ── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag() masks stats::lag()
## ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors
library(psych)
##
## Attaching package: 'psych'
##
## The following objects are masked from 'package:ggplot2':
##
## %+%, alpha
library(corrplot)
## corrplot 0.95 loaded
library(ggplot2)
library(plspm)
## Warning: package 'plspm' was built under R version 4.5.3
##
## Attaching package: 'plspm'
##
## The following objects are masked from 'package:psych':
##
## alpha, rescale, unidim
##
## The following object is masked from 'package:ggplot2':
##
## alpha
2.IMPORT DATA
df <- read.csv("gym_members_exercise_tracking.csv")
3.MELIHAT DATA AWAL
Head Data
head(df)
## Age Gender Weight..kg. Height..m. Max_BPM Avg_BPM Resting_BPM
## 1 56 Male 88.3 1.71 180 157 60
## 2 46 Female 74.9 1.53 179 151 66
## 3 32 Female 68.1 1.66 167 122 54
## 4 25 Male 53.2 1.70 190 164 56
## 5 38 Male 46.1 1.79 188 158 68
## 6 56 Female 58.0 1.68 168 156 74
## Session_Duration..hours. Calories_Burned Workout_Type Fat_Percentage
## 1 1.69 1313 Yoga 12.6
## 2 1.30 883 HIIT 33.9
## 3 1.11 677 Cardio 33.4
## 4 0.59 532 Strength 28.8
## 5 0.64 556 Strength 29.2
## 6 1.59 1116 HIIT 15.5
## Water_Intake..liters. Workout_Frequency..days.week. Experience_Level BMI
## 1 3.5 4 3 30.20
## 2 2.1 4 2 32.00
## 3 2.3 4 2 24.71
## 4 2.1 3 1 18.41
## 5 2.8 3 1 14.39
## 6 2.7 5 3 20.55
Struktur Data
setwd("C:/Users/MSI-PC/Downloads")
str(df)
## 'data.frame': 973 obs. of 15 variables:
## $ Age : int 56 46 32 25 38 56 36 40 28 28 ...
## $ Gender : chr "Male" "Female" "Female" "Male" ...
## $ Weight..kg. : num 88.3 74.9 68.1 53.2 46.1 ...
## $ Height..m. : num 1.71 1.53 1.66 1.7 1.79 1.68 1.72 1.51 1.94 1.84 ...
## $ Max_BPM : int 180 179 167 190 188 168 174 189 185 169 ...
## $ Avg_BPM : int 157 151 122 164 158 156 169 141 127 136 ...
## $ Resting_BPM : int 60 66 54 56 68 74 73 64 52 64 ...
## $ Session_Duration..hours. : num 1.69 1.3 1.11 0.59 0.64 1.59 1.49 1.27 1.03 1.08 ...
## $ Calories_Burned : num 1313 883 677 532 556 ...
## $ Workout_Type : chr "Yoga" "HIIT" "Cardio" "Strength" ...
## $ Fat_Percentage : num 12.6 33.9 33.4 28.8 29.2 15.5 21.3 30.6 28.9 29.7 ...
## $ Water_Intake..liters. : num 3.5 2.1 2.3 2.1 2.8 2.7 2.3 1.9 2.6 2.7 ...
## $ Workout_Frequency..days.week.: int 4 4 4 3 3 5 3 3 4 3 ...
## $ Experience_Level : int 3 2 2 1 1 3 2 2 2 1 ...
## $ BMI : num 30.2 32 24.7 18.4 14.4 ...
Nama Variabel
names(df)
## [1] "Age" "Gender"
## [3] "Weight..kg." "Height..m."
## [5] "Max_BPM" "Avg_BPM"
## [7] "Resting_BPM" "Session_Duration..hours."
## [9] "Calories_Burned" "Workout_Type"
## [11] "Fat_Percentage" "Water_Intake..liters."
## [13] "Workout_Frequency..days.week." "Experience_Level"
## [15] "BMI"
Summary Statistik
summary(df)
## Age Gender Weight..kg. Height..m.
## Min. :18.00 Length:973 Min. : 40.00 Min. :1.500
## 1st Qu.:28.00 Class :character 1st Qu.: 58.10 1st Qu.:1.620
## Median :40.00 Mode :character Median : 70.00 Median :1.710
## Mean :38.68 Mean : 73.85 Mean :1.723
## 3rd Qu.:49.00 3rd Qu.: 86.00 3rd Qu.:1.800
## Max. :59.00 Max. :129.90 Max. :2.000
## Max_BPM Avg_BPM Resting_BPM Session_Duration..hours.
## Min. :160.0 Min. :120.0 Min. :50.00 Min. :0.500
## 1st Qu.:170.0 1st Qu.:131.0 1st Qu.:56.00 1st Qu.:1.040
## Median :180.0 Median :143.0 Median :62.00 Median :1.260
## Mean :179.9 Mean :143.8 Mean :62.22 Mean :1.256
## 3rd Qu.:190.0 3rd Qu.:156.0 3rd Qu.:68.00 3rd Qu.:1.460
## Max. :199.0 Max. :169.0 Max. :74.00 Max. :2.000
## Calories_Burned Workout_Type Fat_Percentage Water_Intake..liters.
## Min. : 303.0 Length:973 Min. :10.00 Min. :1.500
## 1st Qu.: 720.0 Class :character 1st Qu.:21.30 1st Qu.:2.200
## Median : 893.0 Mode :character Median :26.20 Median :2.600
## Mean : 905.4 Mean :24.98 Mean :2.627
## 3rd Qu.:1076.0 3rd Qu.:29.30 3rd Qu.:3.100
## Max. :1783.0 Max. :35.00 Max. :3.700
## Workout_Frequency..days.week. Experience_Level BMI
## Min. :2.000 Min. :1.00 Min. :12.32
## 1st Qu.:3.000 1st Qu.:1.00 1st Qu.:20.11
## Median :3.000 Median :2.00 Median :24.16
## Mean :3.322 Mean :1.81 Mean :24.91
## 3rd Qu.:4.000 3rd Qu.:2.00 3rd Qu.:28.56
## Max. :5.000 Max. :3.00 Max. :49.84
4. PREPROCESSING
Cek Missing Value
colSums(is.na(df))
## Age Gender
## 0 0
## Weight..kg. Height..m.
## 0 0
## Max_BPM Avg_BPM
## 0 0
## Resting_BPM Session_Duration..hours.
## 0 0
## Calories_Burned Workout_Type
## 0 0
## Fat_Percentage Water_Intake..liters.
## 0 0
## Workout_Frequency..days.week. Experience_Level
## 0 0
## BMI
## 0
Cek Data Duplikat
sum(duplicated(df))
## [1] 0
5.STATISTIK DESKRIPTIF
describe(df)
## vars n mean sd median trimmed mad
## Age 1 973 38.68 12.18 40.00 38.79 14.83
## Gender* 2 973 1.53 0.50 2.00 1.53 0.00
## Weight..kg. 3 973 73.85 21.21 70.00 71.85 19.87
## Height..m. 4 973 1.72 0.13 1.71 1.72 0.13
## Max_BPM 5 973 179.88 11.53 180.00 179.94 14.83
## Avg_BPM 6 973 143.77 14.35 143.00 143.62 17.79
## Resting_BPM 7 973 62.22 7.33 62.00 62.29 8.90
## Session_Duration..hours. 8 973 1.26 0.34 1.26 1.26 0.30
## Calories_Burned 9 973 905.42 272.64 893.00 898.76 263.90
## Workout_Type* 10 973 2.49 1.13 3.00 2.49 1.48
## Fat_Percentage 11 973 24.98 6.26 26.20 25.46 5.49
## Water_Intake..liters. 12 973 2.63 0.60 2.60 2.63 0.74
## Workout_Frequency..days.week. 13 973 3.32 0.91 3.00 3.28 1.48
## Experience_Level 14 973 1.81 0.74 2.00 1.76 1.48
## BMI 15 973 24.91 6.66 24.16 24.43 6.33
## min max range skew kurtosis se
## Age 18.00 59.00 41.00 -0.08 -1.22 0.39
## Gender* 1.00 2.00 1.00 -0.10 -1.99 0.02
## Weight..kg. 40.00 129.90 89.90 0.77 -0.04 0.68
## Height..m. 1.50 2.00 0.50 0.34 -0.73 0.00
## Max_BPM 160.00 199.00 39.00 -0.04 -1.19 0.37
## Avg_BPM 120.00 169.00 49.00 0.09 -1.20 0.46
## Resting_BPM 50.00 74.00 24.00 -0.07 -1.19 0.23
## Session_Duration..hours. 0.50 2.00 1.50 0.03 -0.36 0.01
## Calories_Burned 303.00 1783.00 1480.00 0.28 -0.07 8.74
## Workout_Type* 1.00 4.00 3.00 -0.02 -1.38 0.04
## Fat_Percentage 10.00 35.00 25.00 -0.63 -0.35 0.20
## Water_Intake..liters. 1.50 3.70 2.20 0.07 -1.03 0.02
## Workout_Frequency..days.week. 2.00 5.00 3.00 0.15 -0.81 0.03
## Experience_Level 1.00 3.00 2.00 0.32 -1.13 0.02
## BMI 12.32 49.84 37.52 0.76 0.73 0.21
6.VISUALISASI DISTRIBUSI DATA
Histogram Calories Burned
ggplot(df, aes(x = Calories_Burned)) +
geom_histogram(bins = 30, fill = "skyblue") +
theme_minimal() +
labs(
title = "Histogram Calories Burned",
x = "Calories Burned",
y = "Frekuensi"
)

Histogram Fat Percentage
ggplot(df, aes(x = Fat_Percentage)) +
geom_histogram(bins = 30, fill = "orange") +
theme_minimal() +
labs(
title = "Histogram Fat Percentage",
x = "Fat Percentage",
y = "Frekuensi"
)

Histogram Session Duration
ggplot(df, aes(x = Session_Duration..hours.)) +
geom_histogram(bins = 30, fill = "lightgreen") +
theme_minimal() +
labs(
title = "Histogram Session Duration",
x = "Session Duration",
y = "Frekuensi"
)

7.VISUALISASI OUTLIER
Boxplot Fat Percentage
ggplot(df, aes(y = Fat_Percentage)) +
geom_boxplot(fill = "pink") +
theme_minimal() +
labs(title = "Boxplot Fat Percentage")

Boxplot Calories Burned
ggplot(df, aes(y = Calories_Burned)) +
geom_boxplot(fill = "skyblue") +
theme_minimal() +
labs(title = "Boxplot Calories Burned")

Boxplot Workout Frequency
ggplot(df, aes(y = Workout_Frequency..days.week.)) +
geom_boxplot(fill = "orange") +
theme_minimal() +
labs(title = "Boxplot Workout Frequency")

8.DETEKSI OUTLIER MENGGUNAKAN Z-SCORE
Ambil Variabel Numerik
numeric_df <- df %>%
select(where(is.numeric))
Hitung Z-Score
z_scores <- as.data.frame(scale(numeric_df))
Jumlah Outlier
outlier_count <- colSums(abs(z_scores) > 3)
outlier_count
## Age Weight..kg.
## 0 0
## Height..m. Max_BPM
## 0 0
## Avg_BPM Resting_BPM
## 0 0
## Session_Duration..hours. Calories_Burned
## 0 3
## Fat_Percentage Water_Intake..liters.
## 0 0
## Workout_Frequency..days.week. Experience_Level
## 0 0
## BMI
## 10
9.ANALISIS KORELASI
Matriks Korelasi
cor_matrix <- cor(numeric_df)
cor_matrix
## Age Weight..kg. Height..m.
## Age 1.000000000 -0.036339635 -0.027837495
## Weight..kg. -0.036339635 1.000000000 0.365321203
## Height..m. -0.027837495 0.365321203 1.000000000
## Max_BPM -0.017072597 0.057061130 -0.017659884
## Avg_BPM 0.035969143 0.009717478 -0.014776288
## Resting_BPM 0.004353714 -0.032138091 -0.005089864
## Session_Duration..hours. -0.019911904 -0.013665561 -0.010205897
## Calories_Burned -0.154678760 0.095443473 0.086348051
## Fat_Percentage 0.002370051 -0.225511640 -0.235520936
## Water_Intake..liters. 0.041528359 0.394275710 0.393532902
## Workout_Frequency..days.week. 0.008055163 -0.011769328 -0.011269883
## Experience_Level -0.018675927 0.003378528 -0.010266611
## BMI -0.013691370 0.853157690 -0.159468750
## Max_BPM Avg_BPM Resting_BPM
## Age -0.0170725970 0.0359691433 0.004353714
## Weight..kg. 0.0570611305 0.0097174780 -0.032138091
## Height..m. -0.0176598843 -0.0147762881 -0.005089864
## Max_BPM 1.0000000000 -0.0397514432 0.036647481
## Avg_BPM -0.0397514432 1.0000000000 0.059635502
## Resting_BPM 0.0366474807 0.0596355022 1.000000000
## Session_Duration..hours. 0.0100509814 0.0160144382 -0.016648808
## Calories_Burned 0.0020900159 0.3396586672 0.016517951
## Fat_Percentage -0.0090557315 -0.0073016551 -0.016834389
## Water_Intake..liters. 0.0316206428 -0.0029106374 0.007725998
## Workout_Frequency..days.week. -0.0290990657 -0.0106807977 -0.007966891
## Experience_Level 0.0005448337 -0.0008881572 0.001757585
## BMI 0.0671052310 0.0216054995 -0.032542632
## Session_Duration..hours. Calories_Burned
## Age -0.019911904 -0.154678760
## Weight..kg. -0.013665561 0.095443473
## Height..m. -0.010205897 0.086348051
## Max_BPM 0.010050981 0.002090016
## Avg_BPM 0.016014438 0.339658667
## Resting_BPM -0.016648808 0.016517951
## Session_Duration..hours. 1.000000000 0.908140376
## Calories_Burned 0.908140376 1.000000000
## Fat_Percentage -0.581519771 -0.597615248
## Water_Intake..liters. 0.283410977 0.356930683
## Workout_Frequency..days.week. 0.644140366 0.576150125
## Experience_Level 0.764768119 0.694129448
## BMI -0.006492647 0.059760826
## Fat_Percentage Water_Intake..liters.
## Age 0.002370051 0.041528359
## Weight..kg. -0.225511640 0.394275710
## Height..m. -0.235520936 0.393532902
## Max_BPM -0.009055731 0.031620643
## Avg_BPM -0.007301655 -0.002910637
## Resting_BPM -0.016834389 0.007725998
## Session_Duration..hours. -0.581519771 0.283410977
## Calories_Burned -0.597615248 0.356930683
## Fat_Percentage 1.000000000 -0.588682834
## Water_Intake..liters. -0.588682834 1.000000000
## Workout_Frequency..days.week. -0.537059548 0.238562571
## Experience_Level -0.654362613 0.304103549
## BMI -0.119257760 0.213696572
## Workout_Frequency..days.week. Experience_Level
## Age 0.008055163 -0.0186759269
## Weight..kg. -0.011769328 0.0033785279
## Height..m. -0.011269883 -0.0102666112
## Max_BPM -0.029099066 0.0005448337
## Avg_BPM -0.010680798 -0.0008881572
## Resting_BPM -0.007966891 0.0017575852
## Session_Duration..hours. 0.644140366 0.7647681189
## Calories_Burned 0.576150125 0.6941294479
## Fat_Percentage -0.537059548 -0.6543626129
## Water_Intake..liters. 0.238562571 0.3041035494
## Workout_Frequency..days.week. 1.000000000 0.8370787094
## Experience_Level 0.837078709 1.0000000000
## BMI 0.001644974 0.0160310726
## BMI
## Age -0.013691370
## Weight..kg. 0.853157690
## Height..m. -0.159468750
## Max_BPM 0.067105231
## Avg_BPM 0.021605500
## Resting_BPM -0.032542632
## Session_Duration..hours. -0.006492647
## Calories_Burned 0.059760826
## Fat_Percentage -0.119257760
## Water_Intake..liters. 0.213696572
## Workout_Frequency..days.week. 0.001644974
## Experience_Level 0.016031073
## BMI 1.000000000
Heatmap Korelasi
corrplot(
cor_matrix,
method = "color",
type = "upper",
tl.col = "black",
tl.cex = 0.7,
addCoef.col = "black",
number.cex = 0.5
)

10.MODEL SEM-PLS
INNER MODEL
inner <- matrix(c(
0, 0, 0,
0, 0, 0,
1, 1, 0
), nrow = 3, byrow = TRUE)
colnames(inner) <- rownames(inner) <- c(
"Physical_Condition",
"Exercise_Intensity",
"Fitness_Outcome"
)
inner
## Physical_Condition Exercise_Intensity Fitness_Outcome
## Physical_Condition 0 0 0
## Exercise_Intensity 0 0 0
## Fitness_Outcome 1 1 0
OUTER MODEL
outer <- list(
c("Fat_Percentage"),
c("Session_Duration..hours.",
"Workout_Frequency..days.week."),
c("Calories_Burned",
"Experience_Level")
)
MODE REFLECTIVE
modes <- c("A", "A", "A")
11.MENJALANKAN MODEL PLS
pls_model <- plspm(
df,
inner,
outer,
modes = modes
)
12.HASIL MODEL PLS
Summary Model
summary(pls_model)
## PARTIAL LEAST SQUARES PATH MODELING (PLS-PM)
##
## ----------------------------------------------------------
## MODEL SPECIFICATION
## 1 Number of Cases 973
## 2 Latent Variables 3
## 3 Manifest Variables 5
## 4 Scale of Data Standardized Data
## 5 Non-Metric PLS FALSE
## 6 Weighting Scheme centroid
## 7 Tolerance Crit 1e-06
## 8 Max Num Iters 100
## 9 Convergence Iters 4
## 10 Bootstrapping FALSE
## 11 Bootstrap samples NULL
##
## ----------------------------------------------------------
## BLOCKS DEFINITION
## Block Type Size Mode
## 1 Physical_Condition Exogenous 1 A
## 2 Exercise_Intensity Exogenous 2 A
## 3 Fitness_Outcome Endogenous 2 A
##
## ----------------------------------------------------------
## BLOCKS UNIDIMENSIONALITY
## Mode MVs C.alpha DG.rho eig.1st eig.2nd
## Physical_Condition A 1 1.000 1.000 1.00 0.000
## Exercise_Intensity A 2 0.784 0.902 1.64 0.356
## Fitness_Outcome A 2 0.819 0.917 1.69 0.306
##
## ----------------------------------------------------------
## OUTER MODEL
## weight loading communality redundancy
## Physical_Condition
## 1 Fat_Percentage 1.000 1.000 1.000 0.000
## Exercise_Intensity
## 2 Session_Duration..hours. 0.595 0.922 0.849 0.000
## 2 Workout_Frequency..days.week. 0.507 0.890 0.793 0.000
## Fitness_Outcome
## 3 Calories_Burned 0.524 0.914 0.836 0.740
## 3 Experience_Level 0.562 0.926 0.858 0.759
##
## ----------------------------------------------------------
## CROSSLOADINGS
## Physical_Condition Exercise_Intensity
## Physical_Condition
## 1 Fat_Percentage 1.000 -0.618
## Exercise_Intensity
## 2 Session_Duration..hours. -0.582 0.922
## 2 Workout_Frequency..days.week. -0.537 0.890
## Fitness_Outcome
## 3 Calories_Burned -0.598 0.833
## 3 Experience_Level -0.654 0.880
## Fitness_Outcome
## Physical_Condition
## 1 Fat_Percentage -0.681
## Exercise_Intensity
## 2 Session_Duration..hours. 0.906
## 2 Workout_Frequency..days.week. 0.773
## Fitness_Outcome
## 3 Calories_Burned 0.914
## 3 Experience_Level 0.926
##
## ----------------------------------------------------------
## INNER MODEL
## $Fitness_Outcome
## Estimate Std. Error t value Pr(>|t|)
## Intercept 3.17e-17 0.0109 2.91e-15 1.00e+00
## Physical_Condition -1.71e-01 0.0139 -1.23e+01 1.86e-32
## Exercise_Intensity 8.25e-01 0.0139 5.95e+01 0.00e+00
##
## ----------------------------------------------------------
## CORRELATIONS BETWEEN LVs
## Physical_Condition Exercise_Intensity Fitness_Outcome
## Physical_Condition 1.000 -0.618 -0.681
## Exercise_Intensity -0.618 1.000 0.931
## Fitness_Outcome -0.681 0.931 1.000
##
## ----------------------------------------------------------
## SUMMARY INNER MODEL
## Type R2 Block_Communality Mean_Redundancy
## Physical_Condition Exogenous 0.000 1.000 0.000
## Exercise_Intensity Exogenous 0.000 0.821 0.000
## Fitness_Outcome Endogenous 0.885 0.847 0.749
## AVE
## Physical_Condition 1.000
## Exercise_Intensity 0.821
## Fitness_Outcome 0.847
##
## ----------------------------------------------------------
## GOODNESS-OF-FIT
## [1] 0.859
##
## ----------------------------------------------------------
## TOTAL EFFECTS
## relationships direct indirect total
## 1 Physical_Condition -> Exercise_Intensity 0.000 0 0.000
## 2 Physical_Condition -> Fitness_Outcome -0.171 0 -0.171
## 3 Exercise_Intensity -> Fitness_Outcome 0.825 0 0.825
Path Coefficient
pls_model$path_coefs
## Physical_Condition Exercise_Intensity Fitness_Outcome
## Physical_Condition 0.000000 0.0000000 0
## Exercise_Intensity 0.000000 0.0000000 0
## Fitness_Outcome -0.170824 0.8252798 0
Outer Loading
pls_model$outer_model
## name block weight loading
## 1 Fat_Percentage Physical_Condition 1.0000000 1.0000000
## 2 Session_Duration..hours. Exercise_Intensity 0.5948642 0.9216413
## 3 Workout_Frequency..days.week. Exercise_Intensity 0.5073072 0.8904833
## 4 Calories_Burned Fitness_Outcome 0.5241787 0.9144398
## 5 Experience_Level Fitness_Outcome 0.5622309 0.9260788
## communality redundancy
## 1 1.0000000 0.0000000
## 2 0.8494226 0.0000000
## 3 0.7929605 0.0000000
## 4 0.8362001 0.7397217
## 5 0.8576219 0.7586720
Goodness of Fit
pls_model$gof
## [1] 0.858965
Visualisasi Model PLS
plot(pls_model)

13.EVALUASI OUTER MODEL
Outer Loading
pls_model$outer_model[, c("name", "loading")]
## name loading
## 1 Fat_Percentage 1.0000000
## 2 Session_Duration..hours. 0.9216413
## 3 Workout_Frequency..days.week. 0.8904833
## 4 Calories_Burned 0.9144398
## 5 Experience_Level 0.9260788
Diagram Loading Factor
library(ggplot2)
loading_df <- pls_model$outer_model[, c("name", "loading")]
ggplot(loading_df, aes(x = reorder(name, loading), y = loading)) +
geom_bar(stat = "identity", fill = "skyblue") +
coord_flip() +
geom_text(aes(label = round(loading, 3)),
hjust = -0.2,
size = 4) +
ylim(0, 1.1) +
theme_minimal() +
labs(
title = "Diagram Loading Factor",
x = "Indikator",
y = "Loading Factor"
)

Cross Loading
pls_model$crossloadings
## name block Physical_Condition
## 1 Fat_Percentage Physical_Condition 1.0000000
## 2 Session_Duration..hours. Exercise_Intensity -0.5815198
## 3 Workout_Frequency..days.week. Exercise_Intensity -0.5370595
## 4 Calories_Burned Fitness_Outcome -0.5976152
## 5 Experience_Level Fitness_Outcome -0.6543626
## Exercise_Intensity Fitness_Outcome
## 1 -0.6183795 -0.6811601
## 2 0.9216413 0.9060041
## 3 0.8904833 0.7726372
## 4 0.8325053 0.9144398
## 5 0.8795893 0.9260788
Composite Reliability
pls_model$unidim
## Mode MVs C.alpha DG.rho eig.1st eig.2nd
## Physical_Condition A 1 1.0000000 1.0000000 1.000000 0.0000000
## Exercise_Intensity A 2 0.7835588 0.9023474 1.644140 0.3558596
## Fitness_Outcome A 2 0.8194527 0.9172009 1.694129 0.3058706
14.HTMT (DISCRIMINANT VALIDITY)
latent_scores <- pls_model$scores
cor(latent_scores)
## Physical_Condition Exercise_Intensity Fitness_Outcome
## Physical_Condition 1.0000000 -0.6183795 -0.6811601
## Exercise_Intensity -0.6183795 1.0000000 0.9309139
## Fitness_Outcome -0.6811601 0.9309139 1.0000000
15.EVALUASI INNER MODEL
R-Square
pls_model$inner_model
## $Fitness_Outcome
## Estimate Std. Error t value Pr(>|t|)
## Intercept 3.170646e-17 0.01090621 2.907193e-15 1.000000e+00
## Physical_Condition -1.708240e-01 0.01387771 -1.230923e+01 1.856594e-32
## Exercise_Intensity 8.252798e-01 0.01387771 5.946799e+01 0.000000e+00
Korelasi Antar Konstruk
pls_model$inner_summary
## Type R2 Block_Communality Mean_Redundancy
## Physical_Condition Exogenous 0.0000000 1.0000000 0.0000000
## Exercise_Intensity Exogenous 0.0000000 0.8211915 0.0000000
## Fitness_Outcome Endogenous 0.8846229 0.8469110 0.7491969
## AVE
## Physical_Condition 1.0000000
## Exercise_Intensity 0.8211915
## Fitness_Outcome 0.8469110
16.BOOTSTRAPPING
boot_model <- plspm(
df,
inner,
outer,
modes = modes,
boot.val = TRUE,
br = 500
)
17.HASIL BOOTSTRAPPING
Hasil Bootstrap
boot_model$boot
## $weights
## Original Mean.Boot
## Physical_Condition-Fat_Percentage 1.0000000 1.0000000
## Exercise_Intensity-Session_Duration..hours. 0.5948642 0.5951399
## Exercise_Intensity-Workout_Frequency..days.week. 0.5073072 0.5074239
## Fitness_Outcome-Calories_Burned 0.5241787 0.5246443
## Fitness_Outcome-Experience_Level 0.5622309 0.5621030
## Std.Error perc.025
## Physical_Condition-Fat_Percentage 1.184497e-16 1.0000000
## Exercise_Intensity-Session_Duration..hours. 5.927263e-03 0.5845592
## Exercise_Intensity-Workout_Frequency..days.week. 2.888802e-03 0.5019318
## Fitness_Outcome-Calories_Burned 4.145177e-03 0.5168498
## Fitness_Outcome-Experience_Level 5.105846e-03 0.5524206
## perc.975
## Physical_Condition-Fat_Percentage 1.0000000
## Exercise_Intensity-Session_Duration..hours. 0.6076815
## Exercise_Intensity-Workout_Frequency..days.week. 0.5129194
## Fitness_Outcome-Calories_Burned 0.5329544
## Fitness_Outcome-Experience_Level 0.5725002
##
## $loadings
## Original Mean.Boot
## Physical_Condition-Fat_Percentage 1.0000000 1.0000000
## Exercise_Intensity-Session_Duration..hours. 0.9216413 0.9214400
## Exercise_Intensity-Workout_Frequency..days.week. 0.8904833 0.8900496
## Fitness_Outcome-Calories_Burned 0.9144398 0.9142311
## Fitness_Outcome-Experience_Level 0.9260788 0.9257526
## Std.Error perc.025
## Physical_Condition-Fat_Percentage 1.111335e-16 1.0000000
## Exercise_Intensity-Session_Duration..hours. 3.626806e-03 0.9137745
## Exercise_Intensity-Workout_Frequency..days.week. 6.837559e-03 0.8748996
## Fitness_Outcome-Calories_Burned 5.231543e-03 0.9038994
## Fitness_Outcome-Experience_Level 4.096745e-03 0.9174074
## perc.975
## Physical_Condition-Fat_Percentage 1.0000000
## Exercise_Intensity-Session_Duration..hours. 0.9279933
## Exercise_Intensity-Workout_Frequency..days.week. 0.9025100
## Fitness_Outcome-Calories_Burned 0.9239799
## Fitness_Outcome-Experience_Level 0.9334363
##
## $paths
## Original Mean.Boot Std.Error
## Physical_Condition -> Fitness_Outcome -0.1708240 -0.1708611 0.01452828
## Exercise_Intensity -> Fitness_Outcome 0.8252798 0.8251115 0.01114356
## perc.025 perc.975
## Physical_Condition -> Fitness_Outcome -0.1985246 -0.1430608
## Exercise_Intensity -> Fitness_Outcome 0.8048219 0.8464675
##
## $rsq
## Original Mean.Boot Std.Error perc.025 perc.975
## Fitness_Outcome 0.8846229 0.8845061 0.005673789 0.8721605 0.8951751
##
## $total.efs
## Original Mean.Boot Std.Error
## Physical_Condition -> Exercise_Intensity 0.0000000 0.0000000 0.00000000
## Physical_Condition -> Fitness_Outcome -0.1708240 -0.1708611 0.01452828
## Exercise_Intensity -> Fitness_Outcome 0.8252798 0.8251115 0.01114356
## perc.025 perc.975
## Physical_Condition -> Exercise_Intensity 0.0000000 0.0000000
## Physical_Condition -> Fitness_Outcome -0.1985246 -0.1430608
## Exercise_Intensity -> Fitness_Outcome 0.8048219 0.8464675
Tabel T-Statistic dan P-Value
boot_model$inner_model
## $Fitness_Outcome
## Estimate Std. Error t value Pr(>|t|)
## Intercept 3.170646e-17 0.01090621 2.907193e-15 1.000000e+00
## Physical_Condition -1.708240e-01 0.01387771 -1.230923e+01 1.856594e-32
## Exercise_Intensity 8.252798e-01 0.01387771 5.946799e+01 0.000000e+00
Path Bootstrap
boot_model$boot$paths
## Original Mean.Boot Std.Error
## Physical_Condition -> Fitness_Outcome -0.1708240 -0.1708611 0.01452828
## Exercise_Intensity -> Fitness_Outcome 0.8252798 0.8251115 0.01114356
## perc.025 perc.975
## Physical_Condition -> Fitness_Outcome -0.1985246 -0.1430608
## Exercise_Intensity -> Fitness_Outcome 0.8048219 0.8464675
Visualisasi Bootstrap
plot(boot_model)
