IDEMSInternational / R-Instat

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

More on the PICSA rainfall #5039

Open rdstern opened 6 years ago

rdstern commented 6 years ago

Describe the bug This might be fixed when the code is changed for the dates. By themselves they have worked fine for me. They even worked when I had day numbers more than 366, which was a relief.

But I was using data from Dodoma, where there is a shifted year, i.e. starting from 1 August. This is currently ignored. So I had to transform the numbers to those from 1 January to get the right dates. There could be an origin, which would allow for that?

But when I have dates on the y axis the option to get the mean line doesn't work. It doesn't give a line.

So I tried the ordinary plot options. I tried both hline and an ordinary line as an additional layer. That gives a nasty error message. I don't repeat it here, but can add it if you wish. It is easy to get and consistent.

rdstern commented 6 years ago

Another "feature", perhaps not a bug, but interesting. On the total rainfall I am keen to start the y-axis at zero, even if there are no data close to there. When I specify zero as the start and breaks of 200 it still starts at 100 and not zero. I would like more control of these limits.

I found I had to add 2 further elements (they might also be useful in our ordinary plotting.

I finished by adding 2 further arguments, namely limits and expand ,limits=c(1,999),expand=expand_scale(0))

As far as I understand, If I add limits it sort of works, but adds a default of 5% round the stated values. That's the expand argument. If you set that to zero I got what I wanted, namely starting effectively at zero, but without labelling the zero. And having nice labels still at round numbers.

rdstern commented 6 years ago

So here is my list partly from using the graphs for Tanzania. Which was much appreciated. 1) I like the fact that the year column is filled automatically on the main dialogue. But sometimes I start with a data frame with just the summary data, and not necessarily even linked to the daily data. I would either like it to be possible to use a column for the x that is a year column, but isn't defined as such. Or have an easy way to define a column as a year column. Currently I get a date column and then define the sheet as climatic to be able to proceed. Good for discussion. 2) When the x-data are plotted, then they are offset from the tick marks - maybe anyway, but particularly noticable when the x-axis labels are vertical. Can the option be added for this? 3) Could the x axis (year) be a factor? Then it could be the 1934-1935 label which was asked. 4) The size of the x-axis and y-axis labels is already there. I think 12 is a sensible default size. 5) As mentioned above, could there be an option for the date format to start on a nonth other than January. Happy if the default changes, because R-Instat knows, but would also like to be able to do it manually. If I have to choose, then I'll have it just manual, rather than just automatic. 6) Adding the limits together with the facility to choose the extent of overlap (default is 5%. Maybe that's even alright here, because I will usually have zero, but then you don't know what scale to start with. If it is given as 0.05 in each direction (ggplot defaults) then it is clear it is a decimal.

  1. I was asked to make the grid lines darker, because the ones given don't photocopy. I would still like the existing grid-line thickness and colour as the defaults, because I don't like them to be dominant, but PICSA users do. So being able to choose them would be good. (In the main Plot Options they are on Theme > All Options > Panel (More Options).
  2. Fixing the bug with the dates is important. Once dates are chosen I can't afterwards use the Plot Options. (If used before the options apply). 10 The horizontal lines don't plot when the dates are used.
  3. Can there be some properties of those lines? That's currently a luxury.
  4. Being able to add the labels would be very good.
  5. Being able easily to Facet by station, when there are multiple stations. Perhaps a checkbox on main dialogue?
  6. The rug-plot of a logical variable on the x-axis. Initially it may just be a single field on the main dialogue, but I guess there will later be options, that might warrant another tab? Or perhaps it could all go onto a sub-plot.

Sorry - that's quite a list!

dannyparsons commented 6 years ago
  1. When the x-data are plotted, then they are offset from the tick marks - maybe anyway, but particularly noticable when the x-axis labels are vertical. Can the option be added for this?

Could the x axis (year) be a factor? Then it could be the 1934-1935 label which was asked.

The size of the x-axis and y-axis labels is already there. I think 12 is a sensible default size.

As mentioned above, could there be an option for the date format to start on a nonth other than January. Happy if the default changes, because R-Instat knows, but would also like to be able to do it manually. If I have to choose, then I'll have it just manual, rather than just automatic.

Adding the limits together with the facility to choose the extent of overlap (default is 5%. Maybe that's even alright here, because I will usually have zero, but then you don't know what scale to start with. If it is given as 0.05 in each direction (ggplot defaults) then it is clear it is a decimal.

Can there be some properties of those lines? That's currently a luxury.

Being able to add the labels would be very good.

Being able easily to Facet by station, when there are multiple stations. Perhaps a checkbox on main dialogue?

The rug-plot of a logical variable on the x-axis. Initially it may just be a single field on the main dialogue, but I guess there will later be options, that might warrant another tab? Or perhaps it could all go onto a sub-plot.

dannyparsons commented 6 years ago

@rdstern please check the improvements to some of the issues. Those checked above have been done.

rdstern commented 5 years ago

In trying the PICSA graphs the lines no longer show and also I could not change the y-axis. When I make the changes in the dialogue it immediately resets.