Help with tukey

46 views
Skip to first unread message

Barel Mishal

unread,
Apr 5, 2021, 7:08:18 AM4/5/21
to pystatsmodels
there is a way to make a specific model with the Tukey?
like the method in R  glht(glm.model, mcp (group = "Tukey"))  
I am trying to calculate ANCOVA and ANOVA with interaction and get the results but don't know-how. I was trying to use bioforkit library but the output is not true when I am checking this against the R code

hope somebody will see and help I on this problem for a two day now



josef...@gmail.com

unread,
Apr 5, 2021, 10:42:33 AM4/5/21
to pystatsmodels
what's the glm model for this?

My problem was that I didn't see how to use tukey hsd on interaction effects.
tukey assumes independent samples.

It's possible to use tukey for the cell means, i.e. comparing all cells as if they came from a single categorical that represents independent samples.

Josef
 



--
You received this message because you are subscribed to the Google Groups "pystatsmodels" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pystatsmodel...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pystatsmodels/3aa6d6eb-382a-425e-9143-0c240d78f319n%40googlegroups.com.

josef...@gmail.com

unread,
Apr 5, 2021, 11:01:04 AM4/5/21
to pystatsmodels
On Mon, Apr 5, 2021 at 10:42 AM <josef...@gmail.com> wrote:


On Mon, Apr 5, 2021 at 7:08 AM Barel Mishal <barel....@mail.huji.ac.il> wrote:
there is a way to make a specific model with the Tukey?
like the method in R  glht(glm.model, mcp (group = "Tukey"))  
I am trying to calculate ANCOVA and ANOVA with interaction and get the results but don't know-how. I was trying to use bioforkit library but the output is not true when I am checking this against the R code

hope somebody will see and help I on this problem for a two day now

what's the glm model for this?

My problem was that I didn't see how to use tukey hsd on interaction effects.
tukey assumes independent samples.

It's possible to use tukey for the cell means, i.e. comparing all cells as if they came from a single categorical that represents independent samples.

What's the `mcp` function? From which package?

Barel Mishal

unread,
Apr 5, 2021, 11:15:03 AM4/5/21
to pystat...@googlegroups.com
This is R library <library(multcomp)> calr was written in R and js.

About the mean file, I have attached the raw (raw_file_exmple_file_calr.csv) file and the after processing file  (hourly_average_data) here, if it helps with the tukey test. But from what I have understood all the calculation was done on the averages file if you look each group is counted a couple of times for each subject in it. 


hourly_average_data (1).csv
raw_file_exmple_file_calr.csv

josef...@gmail.com

unread,
Apr 5, 2021, 11:32:57 AM4/5/21
to pystatsmodels
I found "mcp". It doesn't have a separate doc string, it's under the glht docstring

```
The mcp function must be used with care when defining parameters of interest in two-way ANOVA
or ANCOVA models. Here, the definition of treatment differences (such as Tukey’s all-pair comparisons
or Dunnett’s comparison with a control) might be problem specific. Because it is impossible
to determine the parameters of interest automatically in this case, mcp in multcomp version 1.0-0
and higher generates comparisons for the main effects only, ignoring covariates and interactions
(older versions automatically averaged over interaction terms). A warning is given. We refer to
Hsu (1996), Chapter 7, and Searle (1971), Chapter 7.3, for further discussions and examples on this
issue.
```

I don't know what they are doing in the case of multiway anovas.

Josef


Reply all
Reply to author
Forward
0 new messages