Dear Adam,
Thanks for reporting this bug in the current version of raster (1.9-92).
You have identified a valid work-around:
rasvals<-raster:::.polygonsToRaster(gSRDF, rasdef, field=gSRDF$TotPop90)
or
rasvals<-raster:::.polygonsToRaster(gSRDF, rasdef, field='TotPop90')
The bug occurs because
I'm using the rasterize command in the raster package to rasterize polygon
data and can't seem to get the rasterize routine to recognize the field
parameter. Here's a working example which illustrates the problem:
#load libraries
library(raster)
library(spgwr)
#load data
data(georgia)
#confirm
Hi group, I am looking for a function and exampling code to run spatial
autocorrelation tests but adapted to lineal habitats. My study area is a
river where I set camera traps at random locations all in the riverbank. I
am using occupancy models for prsence of some mammal species but I need a
way t
Hi!
I am creating netcdf files for climatic daily datasets for 50 years.
The problem is that I end up with huge files when trying just one point, and
I have 2000 more points to add. Am I doing something wrong or is it supposed
to be like this?
The code I am using:
# Make a few dimensions we can
sum should be faster than calc(x, sum) because sum uses rowSums whereas
calc, in this case, would call apply(values(x), 1, sum). calc(x,
function(i) rowSums(i)) should be equivalent to sum (in speed and results).
Whether making a RasterBrick is worth it depends on how many times you will
use these
Dear Thiago,
I don't know what makes sum() more suitable comparing to calc() but I think a
fakt that you are useing a stack (and not a brick) influences also the speed of
processing:
##
library(raster)
r <- raster()
r[] <- 1:ncell(r)
setOptions(todisk=TRUE)
system.time(st <
Thank you!
Yury Ryabov
2012/5/13 Rolf Turner
> On 13/05/12 20:07, Yury Ryabov wrote:
>
>> Hi,
>>
>> A "rhohat" function (in "spatstat" package) has its own built-in legend
>> that appears at the top left corner of the graph. Seems that it is not
>> affected by "par(legend())" or I don't have
On 13/05/12 20:07, Yury Ryabov wrote:
Hi,
A "rhohat" function (in "spatstat" package) has its own built-in legend
that appears at the top left corner of the graph. Seems that it is not
affected by "par(legend())" or I don't have a clue how to write the
corresponding statement. Help on "rhohat" d
Hi,
A "rhohat" function (in "spatstat" package) has its own built-in legend
that appears at the top left corner of the graph. Seems that it is not
affected by "par(legend())" or I don't have a clue how to write the
corresponding statement. Help on "rhohat" does not provide informations
about optio