I am very new to r. I was wondering what I should look into to perform an ANOVA random effects. I have some data that have different treatment groups, and an observed behavioral rates as a dependent variable. Each observation occurs at a particular spatial bin (e.g. bin 1 would represent 0-2mm away from a stimulus treatment while spatial bin 10 would be 18-20mm away)
I am attempting to pool the observations for each treatment and determine if there is a significant difference between the observations at each spatial bin. I want to account for the assay number within each treatment as a possible random effect, and avoid possible pseudo-replication of each measured observation. Additionally, I wanted to determine if there was a linear relationship between the observed rate of behavior with spatial bin.
I was originally using an ANCOVA to look for differences however that no longer seems appropriate. Please let me know what functions/packages I would need to look into. I was looking into using lme4 or something like it to build this model and wanted some feedback on this approach. Any suggestions on a better method for approaching this question would also be greatly appreciated!