Re: [R-sig-Geo] Openbugs doesn't seen to want to thin.. ?

2013-08-26 Thread Virgilio Gómez-Rubio
Hi James, How many areas do you have? Also, 40K seems too much. Try to reduce it to 4K. I believe that this number is not the total number of iterations (including thinning) but the number of iterations to keep after thinning. So, if you set it to a thinning of 10 and 4K iterations OpenBUGS will

Re: [R-sig-Geo] Openbugs doesn't seen to want to thin.. ?

2013-08-26 Thread James Rooney
Hi Virgilio, I just did some testing based on what you said. You are right! Thanks! The number is the number of iterations to keep! This was not obvious to me from any documentation But - great thanks problem fixed. Not familiar with INLA and too far into this to change now but since these

[R-sig-Geo] Openbugs doesn't seen to want to thin.. ?

2013-08-26 Thread James Rooney
Hi all, Doing some spatial smoothing using the BYM model from the ASDAR book. I was using Winbugs but had lots of troubles so switched to Openbugs. Unfortunately having a new problem running out of memory. I have tried to fix it with thinning - however Openbugs does not seem to want to thin. My

[R-sig-Geo] output data from R to SaTScan

2013-08-26 Thread James Rooney
Hi all, So I have created some maps in R, smoothed then using the BYM model in Openbugs and opened the CODA files in R once again to analyze results etc. I would like to now test for clusters using SaTScan and the post smoothing data - but I can find very little info anywhere on how to output

Re: [R-sig-Geo] output data from R to SaTScan

2013-08-26 Thread Hugh Sturrock
Hi James, Not sure how to do that, but check out SpatialEpi and Dcluster packages, I believe they can do a lot of what SaTScan does.. Cheers, Hugh From: roone...@tcd.ie To: r-sig-geo@r-project.org Date: Mon, 26 Aug 2013 16:42:55 +0100 Subject: [R-sig-Geo] output data from R to SaTScan Hi

[R-sig-Geo] how to use levelplot() with a geographic projection

2013-08-26 Thread Waichler, Scott R
Hi, I am making lattice plots with levelplot(), where my data are on a regular grid in longitude and latitude, and I want to plot state boundaries as an overlay for reference. How can I do this so that the plot looks more geographically true, with states having the appearance we are used to?

[R-sig-Geo] Error with STFDF

2013-08-26 Thread Supadog
Hello, I'm having trouble creating an STFDF object from my spacio-temporal data. The object is intended to be used later to perform kriging interpolation. My data looks like this (a few lines): xy tvalue 130 30 497826 6.6 2 960 30 499430 7.4 3 1890 30

Re: [R-sig-Geo] Error with STFDF

2013-08-26 Thread Tom Philippi
If you don't have every time value at every spatial point, then you can't have an STFDF object, as by definition STFDF is a full space by time grid. The equation in the error is part of the definition/requirement for an STFDF object. SDIDF objects don't have that requirement of all times at all

[R-sig-Geo] calculate moving window MAE for point and raster data.

2013-08-26 Thread Dominik Schneider
I would like some help with programming moving window comparison of spatial point data vs raster data. To account for georeferencing errors in the remote sensing data r I'd like to calculate error statistics such as MAE in 250 m increments given a 500m product. So in the example below, a 1km x 1km

Re: [R-sig-Geo] how to use levelplot() with a geographic projection

2013-08-26 Thread Tom Philippi
Scott-- Instead of using lattice::levelplot directly, you can use the raster package for your regular grid data + projection information, and the rasterVis package rasterVis::levelplot. You can then either use panel.spplot to overlay your state outline polygons, or use latticeExtra:layer and

Re: [R-sig-Geo] output data from R to SaTScan

2013-08-26 Thread James Rooney
Hi Hugh, Thanks for your answer. Yes I've seen it said that those packages can do most of what SaTScan does. I'm playing with Kulldorff's Statistic as implemented in section 11.5.6 of ASDAR - but a few things confuse me: 1. How do I decide what the correct value for fractpop is ? I initially

Re: [R-sig-Geo] output data from R to SaTScan

2013-08-26 Thread Hugh Sturrock
Hi JAmes, I'm afraid I've never used the packages so I'm no expert. But in answer to your questions.. 1. Kulldorf recommends a fract pop of 0.5 but I guess if you have a reason to believe there is a different upper limit then you could compare results. Remember, this is the fraction of the

Re: [R-sig-Geo] Problems wirh R 3.0.1 and maptools

2013-08-26 Thread MacQueen, Don
What happens if you try these, derived from the examples in ?rgdal: ## from ?readOGR dsn - system.file(vectors, package = rgdal)[1] ## then read two of the shapefiles in that directory cit - readOGR(dsn,'cities') plot(cit) tmp - readOGR(dsn,'trin_inca_pl03') plot(tmp) They work for me, also

Re: [R-sig-Geo] Error with STFDF

2013-08-26 Thread Supadog
Hi Tom, Thanks for the response. I would like to interpolate for values in the 'value' column given different x, y and t values. I was hoping to use the krigeST function but I just did a little bit of searching and it appears as though it won't work with anything other than STFDF objects. Do I