I have two things to ask. 1) I'm analyzing gene expression data in R. I have pre-processed and normalized my data so now I have 1 file containing normalized values with gene names in the rows and samples in the columns. I want to perform an ANOVA for my genes, use a suitable cut-off and cluster the results to identify groups of genes with similar expression patterns across all my samples. How can I do an ANOVA test in R and plot it?
2) One thing I'm confused about is how to deal with replicate experiments. We are checking expression patterns of each gene at 3 different time points and for each time point we have 3 replicate experiments. For example at time point = 6hrs, we have 3 replicates for our sample treated with "chemical X" and 3 replicates for our sample "without chemical X". Similarly we have used "chemical Y" to treat our samples separately at 6,12 and 24 hrs (each time point with 3 replicate experiments with and without treatment). Should I take the mean of normalized values of the 3 replicates at each time point and then do an ANOVA and cluster? Also can I do an ANOVA on all samples or do I have to do it separately for chemical X and chemical Y?