Skip to content

Commit c3afeec

Browse files
committed
last version
1 parent d3b967e commit c3afeec

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

NEWS

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
spdynmod 1.1
22
-----------------
33

4-
* plot and extdata bugs fixed
5-
* mrgf function added
4+
* plot and Windows compatibility bugs fixed
5+
* Multiple Resolution Goodness of Fit (mrgf) function added
6+
* Imagemagick needs to be installed on the system to run the animations (http://www.imagemagick.org)

R/mrgf.R

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#' A function to perform Multiple Resolution Goodness of Fit.
22
#'
3-
#' Returns the results of a Multiple Resolution Goodness of Fit after the modified method of Kuhnert et al. 2005, originally by Costanza 1989.
3+
#' Returns the results of a Multiple Resolution Goodness of Fit after the modified method of Kuhnert et al. 2005, originally by Costanza 1989. This function is computationally intensive.
44
#'
55
#' @param year year validation year
66
#'
@@ -30,6 +30,7 @@ af@nrows->nr
3030
af@ncols->nc
3131
print(nr)
3232
print(nc)
33+
3334
ft<<-NULL
3435
fwes<-NULL
3536
ees<-NULL
@@ -74,6 +75,10 @@ ees[g]<-ee
7475
sfwes<-sum(fwes)
7576
sess<-sum(ees)
7677
ft<<-sfwes/sess
78+
79+
ft<-get('ft')
80+
fw<-get('fw')
81+
7782
#png(paste('mrgf_',year,'.png',sep=''))
7883
plot(seq(w1,w2,2),fw,ylim=c(0,1),xlab='window size',ylab='Fw',ty='l',main='Multiple Resolution Goodness of Fit',sub=paste('Ft =',round(ft,2),'; k = ',k))
7984
mtext(year,side=3)

man/mrgf.Rd

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Fw vector of fits for each window size
2121
Ft weighted overall fit
2222
}
2323
\description{
24-
Returns the results of a Multiple Resolution Goodness of Fit after the modified method of Kuhnert et al. 2005, originally by Costanza 1989.
24+
Returns the results of a Multiple Resolution Goodness of Fit after the modified method of Kuhnert et al. 2005, originally by Costanza 1989. This function is computationally intensive.
2525
}
2626
\examples{
2727
## Not run mrgf(year='1992',w1=1,w2=113,k=0)

0 commit comments

Comments
 (0)