I have data of the following format from several org
(showing a to d here, some have 3 and some have 4 samples):
org unfiltered filtered
org_a 50.82 67.82
org_a 57.72 58.31
org_a 67.82 55.72
org_a 58.31 52.72
org_b 55.72 57.72
org_b 52.72 51.82
org_b 57.72 52.72
org_c 51.82 63.82
org_c 52.72 66
org_c 63.82 61
org_d 66 62
org_d 61 63
org_d 62 64
org_d 63 62
I have calculated mean
(AVERAGE function in excel) for each org and then standard error
(STDEV.S/SQRT(COUNT(sample1:sample4)) function in excel) by transposing the data manually.
I could see the differences between different org
in the unfiltered plot and filtered plot. I am thinking of applying unpaired t-test to get p-values to show the statistical differences between different org for unfiltered and filtered data separately.
I have used the following code on the original data in R to compute different parameters but unable to go further to compute t-test.
summary(data)
aggregate(data[,2:3],by=list(org=data$org),FUN=mean)
aggregate(data[,2:3],by=list(org=data$org),FUN=sd)
dataMelt <- melt(as.data.frame(data))
g = ggplot(dataMelt)
g = g + geom_boxplot(aes(x=org,y=value))
g = g + facet_wrap(~variable)
g
box plot is not much helpful. I would also like to make barplots for filtered and unfiltered data showing standard error with p-values. Any guidance would be appreciated.