Skip to content

Instantly share code, notes, and snippets.

@sashaphanes
Last active December 17, 2015 02:19
Show Gist options
  • Save sashaphanes/5535090 to your computer and use it in GitHub Desktop.
Save sashaphanes/5535090 to your computer and use it in GitHub Desktop.
#read human data
setwd("/home/rosseraa/work.dir/allen.brain/")
human.raw.data = read.csv("human.common.regions.ANOVA.csv")
#run human ANOVA
aov.result = aov(expression ~ region, data=human.raw.data)
summary(aov.result) #is there a significant difference between any of the group means? If so, move onto a post-hoc test
TukeyHSD(aov.result) #post-hoc for multiple pairwise comparisons to see where the significant differences lie.
summary(aov.result)[[1]][["Pr(>F)"]] #p-values
print(model.tables(aov.result, "means"), digits=4)
boxplot(expression ~ region, data=human.raw.data, pch=20)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment