running multiple t-tests across large dataset I'm trying to work out if a t-test is the most appropriate in this situation:
I have a data frame which looks like the one below but my data frame has aprox 37,000 rows. I'd like to run a t-test on each row, to check for a difference in mean between all sampleA values and all sampleB values.
In other words, i'd end up running 37,000 individual t-tests since I would be running them along the rows. Each gene can be thought of as independant from all other genes.
I'm currently running a two tailed t-test and wondered if this is appropriate? Would it be wise to run a Benjamini/Hochberg (non-negative) test to get false discovery rate? I'm thinking a FDR with alpha = 0.01 would be appropriate?
thanks
gene    sampleA1   sampleA2    sampleA3 ... sampleA6  sampleB1   sampleB2  sampleB3 ..sampleB7
TP53    2         3           0             5         0         0         0          3
FOXO    4         0           1             2         0         0         1          1
GV13    2         2           0             0         0         0         0          0


First of all, it is fundamental to perform multiple hypothesis corrections of some sort. Benjamini/Hochberg correction is good if you are doing discovery, and it is usually applied in this context. The Bonferroni correction is much more strict but can be useful if you want to be highly conservative. Alpha = 0.01 is a good idea, you could also consider lowering it to alpha = 0.05 and maybe put additional constrain on the minimal difference between the groups. This is because you might care about genes that have at least a certain difference and ignore the others (even if significant).
In principle, doing the t-test is not per se a wrong idea when dealing with such problems, so your line of reasoning makes sense.
However, consider that many excellent statistical models deal with this kind of data. From your snapshot, I can guess that you are dealing with RNA-seq count data, is that the case? If so, I'd recommend you to check out DESEQ2 or EdgeR, statistical models tailored for this setting. If those are counts, then a t-test would not be the best choice, and such models are better at dealing with the intrinsic characteristic of count data.
EDIT: I added some details.
