predgraphics: Prediction graphics for SAEM Algortihm for censored spatial...

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/predgraphicsfin.R

Description

This function provides prediction raster graphics representation and its standard deviation.

Usage

1
2
3
4
5
predgraphics(xpred = NULL, grid1, est, points = T,obspoints = 1:sum(est$cc == 0),
colors = terrain.colors(100),sdgraph = T,xlab="X Coord",ylab="Y Coord",
main1="Predicted response", main2="Standard deviation predicted",
xlim=c(min(est$coords[,1]),max(est$coords[,1])),ylim=c(min(est$coords[,2]),
max(est$coords[,2])))

Arguments

xpred

x design matrix for the prediction coordinates (must be specified when est$trend="other").

grid1

grid with the coordinates of the prediction graphics.

est

object of class "SAEMSpatialCens".

points

(logical), it indicates if some of the observed points may be plotted in the prediction raster graphic (default, points=TRUE).

obspoints

(vector) if points=TRUE, it indicates which of the observed (not censored) values may be plotted in the prediction raster graphics.

colors

colors pallete used for the graphics (By default terrain.colors(100)).

sdgraph

(logical) it indicates if the standard deviation of the prediction points graphic must be plotted (default sdgraph=TRUE).

xlab

label for x coordinate of the two plots.

ylab

label for y coordinate.

main1

an overall title for the prediction plot.

main2

an overall title for the standard deviation prediction plot.

xlim

x axis limits for the two plots.

ylim

y axis limits for the two plots.

Value

in addition to the raster graphics for prediction, the next values are retorned:

datapred

data.frame with the coordinates and the predicted points used in the prediction raster graphic.

datasdpred

data.frame with the coordinates and the standard deviation predicted points used in the standard deviation prediction raster graphic.

Author(s)

Alejandro Ordonez <<[email protected]>>, Victor H. Lachos <<[email protected]>> and Christian E. Galarza <<[email protected]>>

Maintainer: Alejandro Ordonez <<[email protected]>>

References

DELYON, B., LAVIELLE, M.,ANDMOULI NES, E. (1999). Convergence ofa stochastic approximation version of the EM algorithm.Annals of Statistic-s27, 1, 94-128.

Diggle, P. & Ribeiro, P. (2007). Model-Based Geostatistics. Springer Series in Statistics.

See Also

SAEMSCL

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
## Not run: 
data(depth)
cc=depth$cc
y=depth$depth
coords=depth[,1:2]

cov.ini=c(1500,30)
est=SAEMSCL(cc,y,cens.type="left",trend="cte",coords=coords,M=15,perc=0.25,
MaxIter=100,pc=0.2,cov.model="gaussian",fix.nugget=F,nugget=10,
inits.sigmae=cov.ini[2],inits.phi=cov.ini[1], search=T,lower=c(0.00001,0.00001),
upper=c(10000,100))


coorgra1=seq(min(coords[,1]),max(coords[,1]),length=50)
coorgra2=seq(min(coords[,2]),max(coords[,2]),length=50)

grid1=expand.grid(x=coorgra1,y=coorgra2)
xpred=rep(1,2500)

predgraphics(xpred=xpred,est=est,grid1=grid1,points=T,sdgraph=T)


## End(Not run)

CensSpatial documentation built on May 30, 2017, 8:24 a.m.