IDEMSInternational / R-Instat

A statistics software package powered by R
http://r-instat.org/
GNU General Public License v3.0
38 stars 102 forks source link

Move the Percentage sub-dialog into the Summaries sub-dialog in Prepare > Data Reshape > Column Summaries #8729

Closed rdstern closed 5 months ago

rdstern commented 6 months ago

The calculation system in R-Instat is one of our "selling points". It needs a presentation (including video) and to be well reported in the help. As preparation this is the first of 3 urgent(?) issues we need to undertake.

I need an initial discussion with @volloholic before this work. I'll report once that's done.

This one is to get rid of the Propn and Percentages button and sub-dialog from this dialog. Instead it adds a tab to the summaries sub-dialog.

image

Instead - and I hope this will be easy to do - it is just called Percentages, and becomes a further tab on the Summaries sub-dialog.

I think this (with small changes) just needs to be transferred (and corrected) to become the last tab in the existing Summaries sub-dialog.

Here it is:

image

a) We still need the checkbox at the top, simplify the label to become Calculate Percentages. b) Then, either we implement the other radio buttons at the top, or let's get rid of them. c) Check, notice this is a different data frame here to the main dialog. I think this should not be allowed, so the dataframe part of the data selector is disabled. d) Correct the R code. I think it works ok when factors are included, but it should also work when they are omitted? I assume, with this example it should add the percentage of values for each variety. Currently it doesn't. (This may need a quick input from @lilyclements, but I suggest that could come after the transfer has been completed.

lilyclements commented 5 months ago

Instead - and I hope this will be easy to do - it is just called Percentages, and becomes a further tab on the Summaries sub-dialog.

@rdstern I agree with this change.

I think it works ok when factors are included, but it should also work when they are omitted? I assume, with this example it should add the percentage of values for each variety.

By this, do you mean that you would expect the percentage of values for each variety when the variable "Variety" is in the "Summarise by" receiver, but not in the sdg multiple receiver?

This is working as I would expect. If we had multiple factors in our "Summarise by" receiver, but wanted only row percentages and not column percentages, we wouldn't want to do the percentage by all variables in our "Summarise by" receiver. Or am I misunderstanding your point? Could the multiple receiver on the sub dialog contain the variables in the "Summarise by" receiver by default, but can be removable, or is that too complex for the user?

rdstern commented 5 months ago

@lilyclements thanks for the comments. I have been trying the existing button a little and have the impression that it is working ok, and is already pretty powerful. I think that includes all your column and row percentages for frequencies and also percentages of anything else, e.g. percentage change in mean rainfall, where there is quite a lot of choice in how we define the "mean rainfall" as we summarise.

There may be more to be done, but my hope is first to leave the sub-dialog (with its current R-code) exactly as it is. So we just move it into the Summarise sub-dialog. That makes the Prepare > Data Reshape > Column Summaries main dialog a bit simpler, because we lose the second button. Of course the sub-dialog is a bit more complicated.

But the big improvement is then that the single sub-dialog is then also immediately there for the now single sub-dialog that is also called by the Tables, (and the one-variable and 2/3 Variables Summarise) dialogs in the describe menu. That's a big change.

Once it is moved I would like to return to some of your questions above, to see if mmore is needed in addition to sorting out the documentation.

lilyclements commented 5 months ago

@rdstern sounds like a good plan - and hopefully shouldn't be difficult to shift it over. Who do you suggest takes this on?

rdstern commented 5 months ago

@lilyclements agreed and I hope to tell you when we discuss this afternoon. I've sent a skype request to @N-thony to discuss this, but he has yet to answer.

rdstern commented 5 months ago

@N-thony I reflected following our discussion. To make it really easy I propose as follows on the More tab of the current sub-dialog.:

image

a) For now we simplym make the Kurtosis box smaller - perhaps 1/3 its current size. T hen add another with label Percentages. It has a checkbox, default unchecked, with label Add Percentages There is also a button with label Options. If that is pressed, then it opens the current Percentages sub-dialog. It is exactly as now, with the checkbox checked, (or omitted).