Functions/within_variance_comp_emmeans.R

within_variance_comp_emmeans = function(ind,peptide,data,metacond){
  tempdata <- cbind(reponse=data[peptide,,ind],data.frame(fact=factor(metacond)))
  templm <- lm(reponse~fact,data=tempdata)
  return(vcov((emmeans::emmeans(templm,specs = "fact"))))
}
mariechion/mi4p documentation built on Oct. 3, 2024, 4:50 a.m.