Publications by Peihang Li, Juan Carlos

Document

06.12.2024

Question 1 Two Sample T test dat <- read.csv("https://raw.githubusercontent.com/tmatis12/datafiles/refs/heads/main/lifespans.csv") boxplot(Lifespan~Supplier, data = dat, main = "Boxplot of Lifespans by Supplier", xlab = "Supplier", ylab = "Lifespan (hours)") library(car) ## Loading required package: carData levene_...

1959 sym R (3457 sym/22 pcs) 5 img

Document

23.11.2024

6.8 time <- rep(c(12, 18), each = 6) medium <- c(rep(1,6),rep(1,6),rep(2,6),rep(2,6)) growth <- c(21,22,23,28,20,26,37,39,38,38,35,36,25,26,24,25,29,27,31,34,29,33,30,35) time<-as.factor(time) medium<-as.factor(medium) data <- data.frame(time, medium, growth) data ## time medium growth ## 1 12 1 21 ## 2 12 1 22 ## 3 12...

4125 sym R (18587 sym/92 pcs) 27 img

Document

21.11.2024

Introduction This document provides an example of factorial design analysis. The analysis covers hypothesis testing, interaction effects, and ANOVA table creation. Problem Statement We analyze the strength of plastic forks, varying two factors: 1. Type of Plastic: PVC and ABX 2. Thickness: 1mm, 1.5mm, 2mm Each factor level combination is observed ...

2623 sym R (1409 sym/7 pcs) 1 img

Document

25.10.2024

5.2 a. MS_A <- 0.0002 SS_B <- 180.378 SS_Interaction <- 8.479 SS_Error <- 158.797 SS_Total <- 347.653 DF_A <- 1 DF_Interaction <- 3 DF_Error <- 8 DF_Total <- 15 DF_B <- 3 SS_A <- MS_A * DF_A MS_B <- SS_B / DF_B MS_Interaction <- SS_Interaction / DF_Interaction MS_Error <- SS_Error / DF_Error MS_Total <- SS_Total / DF_Total F_A <- MS_A / MS_Error...

796 sym R (5438 sym/17 pcs) 8 img

Document

11.10.2024

3.23 a. \(H_0: \mu_1=\mu_2 =\mu_3=\mu_4=\mu\) \(H_a\): At least one \(\mu\) is not the same. library(tidyr) f1<-c(17.6,18.9,16.3,17.4,20.1,21.6) f2<-c(16.9,15.3,18.6,17.1,19.5,20.3) f3<-c(21.4,23.6,19.4,18.5,20.5,22.3) f4<-c(19.3,21.1,16.9,17.5,18.3,19.8) dat <- data.frame(f1,f2,f3,f4) dat2 <- pivot_longer(dat,c(f1,f2,f3,f4)) aov.model <- aov(valu...

2022 sym R (5434 sym/60 pcs) 8 img

Document

10.10.2024

Yes, this is a valid Latin Square since each letter occur on ly once in each column and row. \(y_{ijk}=\mu+\tau_i+\beta_j+\alpha_k+\epsilon_{ijk}\) batch <- c(rep(1,5),rep(2,5),rep(3,5),rep(4,5),rep(5,5)) day <- c(seq(1,5),seq(1,5),seq(1,5),seq(1,5),seq(1,5)) value <- c(8,7,1,7,3,11,2,7,3,8,4,9,10,1,5,6,8,6,6,10,4,2,3,8,8) ingre <- c('A','B','D','C...

287 sym

Document

08.10.2024

Question1 Hypothesis: \(H_0: \tau_i =0\) \(H_a: \tau_i \neq 0\) Linear effects equation: \(y_{ijk}=\mu_i+\tau_i+\beta_j+\epsilon_{ijk}\) library(GAD) obs <- c(73,68,74,71,67, 73,67,75,72,70, 75,68,78,73,68, 73,71,75,75,69) chemical <- c(rep(1,5),rep(2,5),rep(3,5),rep(4,5)) bolt <- c(rep(seq(1:5),4)) chemical <- as.fixed(c...

869 sym R (1043 sym/4 pcs)

Document

26.09.2024

For max var, we need at least 11, for min var, we need at least 19, for intermediate, we need at least 21. library(pwr) ?power.anova.test power.anova.test(groups = 4, n = NULL, between.var = var(c(18,18,20,20)), within.var = 3.5, sig.level = 0.05, power = 0.80) ## ## Balanced one-way analysis of variance power calculation ## ## g...

322 sym R (2377 sym/12 pcs) 5 img

Document

13.09.2024

2.24 Null Hypothesis: Machine A and Machine B have the same mean net filling volume. Alternative Hypothesis: Machine A and Machine B have different mean net filling volume. volume_A <- c(16.03, 16.04, 16.05, 16.05, 16.02, 16.01, 15.96, 15.98, 16.02, 15.99) volume_B <- c(16.02, 15.97, 15.96, 16.01, 15.99, 16.03, 16.04, 16.02, 16.01, 16.00) qqnorm(...

2963 sym R (5664 sym/48 pcs) 14 img

FA5_Group5

10.09.2024

Question 1 alpha <- 0.05 power <- 0.75 delta <- 0.015 sd <- 0.03 power.t.test(n=NULL, delta = 0.015, sd = 0.03, power = 0.75, sig.level = 0.05, type = c("paired"), alternative = c("one.sided")) ## ## Paired t test power calculation ## ## n = 22.92961 ## delta = 0.015 ## sd = 0.03 ## sig.level = 0.0...

133 sym R (1194 sym/5 pcs)