-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to plot delta changes and it signification in the same map (spatialPlot) #8
Comments
**Hi, The problem is in the sig_points object, since it is a list of 12 (one per season). I recommend you to loop over the months and add a member of sig_points object one at a time to spatialPlot, such that:** figs <- lapply(1:12, FUN = function(z) { Finally you can call the By the way, climate4R.value do not capsulate the t-test statistic, but you can consider the p-value of the KS-statistic which can be computed by setting measure.code = "ts.ks.pval" in valueMeasure function, as an alternative to the t-test. This is just in case you want to fully depend on climate4R, you approach with the t-test and easyveri2grid seems reasonable for me. Please let me know if you attain your desired plots. Cheers, Jorge |
Hi, |
Hi Jorge, Thanks a lot. I understood the point. However I followed the suggestion fro Bedia which is simplest for my specific case. I works for me and the plots are find now. Nevertheless I will use your approach in other scripts we are building. devtools::install_github("SantanderMetGroup/VALUE") Regards Abel |
Hi Joaquin |
Hi, Try devtools::install_github("SantanderMetGroup/[email protected]") Regards, Jorge |
Hola Jorge, muchas gracias. Espero que todo me funcione bien. En cualquier
caso te mantendré informado. Gracias y saludos
Abel
El mar, 1 jun 2021 a las 12:00, Jorge Baño-Medina ***@***.***>)
escribió:
… Hi,
Try ***@***.***")
Regards,
Jorge
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#8 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALEOW3GVOBK7CVRY7CDYESDTQT7Y5ANCNFSM45VGNZUA>
.
|
Hola Joaquin. Muchas gracias. Era bien simple y todo me funcionó perfecto
ahora. Agradezco mucho la respuesta/ayuda
Saludos
Abel
El lun, 31 may 2021 a las 10:37, Joaquin Bedia ***@***.***>)
escribió:
… Hi,
*"[...] and made a list of 12 with the respective sig_points"*.
At this point, you must include the argument which in each element of the
list, so the first stippling goes to subpanel 1 (which = 1), the second
to subpanel 2 (which = 2) and so on. There is an example (not exactly
your case, but it may help) in ?map.stippling. I hope this helps.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#8 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALEOW3FXNU37W6NTJ6BU34DTQONMNANCNFSM45VGNZUA>
.
|
Hi
I calculated the delta change between the climatologies for history (climH) and future (climF) precip and put the result on a grid (change)
climH <-climatology(subH)
climF <- climatology(subF)
change<-gridArithmetics(climF,climH,climH,c,operator = c("-","/","*"))
As I don't found a way (in climate4R) to estimate the statistical signification of the changes I did this with my own script based on t.test using subH and subF grids. Then I produced a grid (named r) with 1 and 0 (1 significant). After that I applied sig<-easyVeri2grid(r,subH) and then sigpoint<-map.stippling(sig,threshold = 1, condition = "GE",pch=16,col="black",cex=0.5).
Finally, I got a proper plot with the precip changes and points where the changes are significant. I used the following
spatialPlot(change,main=list(c("Precip Changes 2021-2040 vs 1961-1990"),cex=2),
xlab=list("Longitude",cex=1.5),ylab=list("Latitude",cex=1.5),
colorkey = list(space = "right",title="(%)",cex=2),
backdrop.theme = "coastline",scales=list(draw=TRUE,cex=1),
col.regions = colorRampPalette(colraindelta),
set.min = -50,set.max=50,sp.layout=list(sig_points))
The above is just for one season or a month. Thus as I want to make a multipanel plot using spatialPlot with a multigrid I create a multigrid using multg<-makeMultiGrid(changes 1..12,skip.temporal.check = TRUE) and made a list of 12 with the respective sig_points. Then
mons<-c("JAN","FEB","MAR","APR","MAY","JUN","JUL","AUG","SEP","OCT","NOV","DEC")
spatialPlot(change,main=list(c("Precip Changes 2021-2040 vs 1961-1990"),cex=2),
xlab=list("Longitude",cex=1.5),ylab=list("Latitude",cex=1.5),
colorkey = list(space = "right",title="(%)",cex=2),
names.attr=mons,as.table=TRUE,
backdrop.theme = "coastline",scales=list(draw=TRUE,cex=1),
col.regions = colorRampPalette(colraindelta),
set.min = -50,set.max=50,sp.layout=list(sig_points))
I got a multipanel plot with the changes for every month but the stippling is always the same for every panel. I believe that I'm doing something wrong.
Can somebody explain to me what is wrong or if there is another way to plot the change field with the significance?
The text was updated successfully, but these errors were encountered: