heat_cor_two <- cor(two_min_bout, use = “complete.obs”)
png(“heatmap_two_min.png”, width = 800, height = 600) pheatmap(heat_cor_two, color = colorRampPalette(c(“green”, “white”, “red”))(50), display_numbers = TRUE, cluster_rows = FALSE, cluster_cols = FALSE, main = “Two-Minute Bouts Correlation Heatmap”) dev.off()
heat_cor_four <- cor(four_min_bout, use = “complete.obs”)
pheatmap(heat_cor_four, color = colorRampPalette(c(“blue”, “white”, “red”))(50), display_numbers = TRUE, cluster_rows = FALSE, cluster_cols = FALSE, main = “Four-Minute Bouts Correlation Heatmap”)
# Calculate the correlation matrix for six-minute bouts
heat_cor_six <- cor(six_min_bout, use = “complete.obs”)
pheatmap(heat_cor_six, color = colorRampPalette(c(“purple”, “white”, “orange”))(50), display_numbers = TRUE, cluster_rows = FALSE, cluster_cols = FALSE, main = “Six-Minute Bouts Correlation Heatmap”) # Calculate the correlation matrix for sedentary bouts heat_cor_sed <- cor(sedentary_bouts, use = “complete.obs”)
pheatmap(heat_cor_sed, color = colorRampPalette(c(“pink”, “white”, “brown”))(50), display_numbers = TRUE, cluster_rows = FALSE, cluster_cols = FALSE, main = “Sedentary Bouts Correlation Heatmap”)
# Calculate the correlation matrix for total physical activity bouts
heat_cor_pa <- cor(total_pa_bouts, use = “complete.obs”)
pheatmap(heat_cor_pa, color = colorRampPalette(c(“yellow”, “white”, “black”))(50), display_numbers = TRUE, cluster_rows = FALSE, cluster_cols = FALSE, main = “Total Physical Activity Bouts Correlation Heatmap”)