Skip to content

Conversation

Kucharssim
Copy link
Member

@Kucharssim Kucharssim requested a review from JohnnyDoorn August 1, 2025 15:53
Copy link
Contributor

@vandenman vandenman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code looks good. I still need to run it inside JASP.

@JohnnyDoorn
Copy link
Contributor

I like the option to have these choices, but one thing I worry about a bit is that now 99% of the users might be confused about which option to choose when they want "the mean". I am also not so well-versed in the different types of means, so can definitely sympathize. Would it be an option to keep calling the arithmetic mean "mean", so indicate that this is the "default" mean? Just like in R, where calling mean() just gives the one type. Then in the infofield (which now also shows up as tooltip), we call it arithmetic mean to specify the type of mean? I think that would keep the interface more userfriendly, while giving the option to users to also calculate different types of means. Anyway just a thought and curious to hear your opinion on this!

@EJWagenmakers
Copy link

Is there a screenshot of what that looks now?

@Kucharssim
Copy link
Member Author

Kucharssim commented Aug 22, 2025

Currently this PR implements it like so (the arithmetic mean is selected by default)

Screenshot 2025-08-22 at 09 13 42

I am not opposed to do it differently if there is a concensus on that

@EJWagenmakers
Copy link

And we have a tooltip on the the different kinds of means? So the alternative, @JohnnyDoorn, is to have "Mean" underneath "Median", and have this be the arithmetic mean; then the two additions need to be somewhere below. But how would this look, exactly?

@Kucharssim
Copy link
Member Author

Screenshot 2025-08-22 at 09 40 30

The help files (and tooltips) do not say much atm, I could add the formulas to make the definitions clearer?

@Kucharssim
Copy link
Member Author

For example, I could add this to the arithmetic mean tooltip

Screenshot 2025-08-22 at 09 49 16

@JohnnyDoorn
Copy link
Contributor

Yes I like those helpfile entries!
As for the qml layout - what would you think of keeping the current (0.95) layout, but adding a dropdown behind the mean checkbox, rather than individual checkboxes? That means that the user cannot request multiple means at the same time, but it keeps the layout a bit more minimal, and more consistent with the other tendency options (i.e., " "); as it looks now (in this PR), the indentation of "Mean" looks a little wonky and is not as clearly part of the "Central tendency" options (although I like that better than not having any indentation before "Mean"). Another option would be to keep the checkbox for Mean, and have radio buttons for the type of mean (same drawback as with he dropdown though).
Again, just a thought and curious to hear what the rest thinks!

@Kucharssim
Copy link
Member Author

Kucharssim commented Aug 27, 2025

I agree that dropdown/radiobuttons would make the UI a bit cleaner, but it assumes users would never want to see different means next to each other in the same table. Is it reasonable to make such an assumption? Most of the time probably yes, but I can imagine we would receive a feature request sometime down the line to make it possible to calculate multiple means at the same time...

If the visual indentation of the mean options is an issue, we could also flatten it like so

Central tendency
[ ] Mode
[ ] Median
[ ] Mean (arithmetic)
[ ] Mean (geometric)
[ ] Mean (harmonic)

alternatively "Artihmetic mean", "Geometric mean", and "Harmonic mean". What do you think?

@vandenman
Copy link
Contributor

I like the idea of one flat list, like

Central tendency
[ ] Mode
[ ] Median
[ ] Mean (arithmetic)
[ ] Mean (geometric)
[ ] Mean (harmonic)

but I'm not sure about the parentheses in the labels. What about:

Central tendency
[ ] Mode
[ ] Median
[ ] Arithmetic mean
[ ] Geometric mean
[ ] Harmonic mean

I don't have a very strong for either of the two, but @EJWagenmakers might?

Either way, let's decide on the GUI and merge this PR before it becomes "one of those PRs" that's open for years.

@vandenman
Copy link
Contributor

Actually, it's also a bit unclear if the two new means fit the category of "Central tendency"...

@JohnnyDoorn
Copy link
Contributor

If we go with any of the two options suggested by @vandenman I would prefer the first one, since it puts the most recognizable thing in the front ("Mean"). And if then the arithmetic mean is also the one ticked by default, it hopefully doesn't confuse users too much...

@Kucharssim
Copy link
Member Author

Actually, it's also a bit unclear if the two new means fit the category of "Central tendency"...

Yes I think they do: https://en.wikipedia.org/wiki/Central_tendency#Measures.

As I indicated before, I am fine with either options listed by @vandenman, but also keeping the options nested as they are currently. Best would be for @EJWagenmakers to give a final answer 🙂

@EJWagenmakers
Copy link

Let's try option 1 then!

@Kucharssim
Copy link
Member Author

Ok, option 1 it is then!

This is how the options menu looks like

Screenshot 2025-09-23 at 17 01 08

And the help file

Screenshot 2025-09-23 at 17 01 26

Copy link

codecov bot commented Sep 23, 2025

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

Thanks for integrating Codecov - We've got you covered ☂️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants