Michel,
I am no expert on ggplot2 and cannot explain why, but it seems the NAs
in map.df.l$value cause some problems. Try to remove them before
plotting or examine your code to figure out why you get them. They seem
to be on the borders between NUTS2-level objects.
Best wishes,
Jon
On 06-F
Hi Ernesto,
I think the issue is that the mahal function treats the arguments
differently depending on the class.
If you pass the arguments x and p as raster and data.frame/matrix, it
will use the values of x at the locations defined in p as training data.
If you pass a data.frame, it will assu
Hi Kristi,
it takes a few extra steps to create a raster layer from your example
data set, as it is not a gridded map in Lat lon (probably in some
projection though). How exactly to do it depends on your data, but here
are some hints:
1. If you actually need to read the data set from a link,
I also wanted to add the result from my Windows machine (R 3.0.0) to the
answer below:
> ncore = system('nproc')
> ncore
[1] 127
# My machine was not happy about starting a cluster with 127 nodes though.
Best wishes,
Jon
On 18-Apr-13 15:13, Jon Olav Skoien wrote:
I don
I dont think this has anything to do with the snow package, you should
rather start by checking what is the output of system('nproc') is on
your computer, and also whether it is possible to assign this to a
variable. I tried on a redhat linux (R 2.15.0) server:
> ncore = system('nproc')
16
> n
Thanks a lot, that seems to do exactly what I need!
Best wishes,
Jon
On 16-Apr-13 10:21, peter dalgaard wrote:
Is this what you are looking for?
FUN = eval(bquote(function(x) .(parse(text = fstring)[[1]])))
FUN
function (x)
x + 2
FUN(3)
[1] 5
On Apr 16, 2013, at 09:50 , Jon Olav Skoien
Dear list,
I am trying to create a function from a string, and have so far solved
it with eval(parse()). This works well also when using the newly created
function as an argument to another function. The trouble starts when I
want to use it with parLapply. Below is a much simplified example:
I am not sure which soil example you refer to (meuse?), but it should
anyway be fairly easy to get a single interpolation, just give a single
point as the prediction location. The easiest is probably to start with
the automap package or the intamap package, where the variogram fitting
etc is do
Nishani,
we do not have access to your data, but I guess the problem is the size
of the observation data set. I think the default of predict.gstat is to
create one covariance matrix between all observation locations, which
would be a 50,000*50,000 matrix in your case. The alternative is to do
I would also suggest the package raster, which usually make it much
easier to extract spatial NetCDF-data than direct use of the
NetCDF-packages.
Bests,
Jon
On 22-Feb-13 17:14, Marc Schwartz wrote:
NetCDF is a binary file format and will be stripped by the list server filters.
Don't bother a
Hi Dimitris,
The mistake is that predict.gstat doesnt have a "model" argument, as you
assume. But as the function also accepts arguments through ..., it does
not complain about the unused argument.
Try instead to put the model argument in the gstat-object as you can see
in the example in ?pred
Uwe,
I am unfortunately not able to upgrade to R 2.15.2 right now, but I have
seen a similar problem with several older R versions. If you want to
test with a shorter script, you can try the lines below. These provoke a
crash from a fresh R session on my machine (R 2.15.1 Windows 7):
Rprof()
Jan,
There are a lot of packages that can help you, the best one depends on
your needs (with or without prediction uncertainty, format of results,
different options) and the size of your problem.
CRAN has a spatial Task View
http://cran.r-project.org/web/views/Spatial.html
with a short descrip
On 08-Mar-12 12:45, Prof Brian Ripley wrote:
> On Thu, 8 Mar 2012, Jon Olav Skoien wrote:
>
>> Hi,
>>
>> One of the functions I use needs to write to a temporary file, in the
>> directory given by tempdir(). I want to change this from the standard
>> one, as
Hi,
One of the functions I use needs to write to a temporary file, in the
directory given by tempdir(). I want to change this from the standard
one, as the file is too large for the drive. However, tempfile() doesnt
seem to respect the environment variables when I change them with
Sys.setenv(
Hi,
I am developing a package B that, among other things, also offers some
extra S3-methods for functions in package A if the user has installed A.
I do not want to list A under Depends of B, as the dependency list of A
is rather long, and most potential users of B will not be interested in
p
Dear list,
I have a data.frame with segments between river junctions and
dimensionless predictions of runoff (runoff/area) at some of these
junctions. As I want to plot my values on a continuous river network
(this data.frame is part of a SpatialLinesDataFrame), I would like to
change NA valu
Pearl,
You find the prediction error as the var1.var column in your result
object, i.e., y in your script. For plotting:
spplot(y, 2)
or
spplot(y,"var1.var")
Jon
On 1/5/2011 9:28 PM, pearl may dela cruz wrote:
Hi ALL,
Can you please help me on how to determine the prediction error for or
On 1/7/2011 12:40 PM, Jon Olav Skoien wrote:
Pearl,
The error suggests that there is something wrong with x2, and that
there is a difference between the row names of the coordinates and the
data. If you call
str(x2)
see if the first element of @coords is different from NULL, as this
can
Pearl,
The error suggests that there is something wrong with x2, and that there
is a difference between the row names of the coordinates and the data.
If you call
str(x2)
see if the first element of @coords is different from NULL, as this can
cause some problems when cross-validating. If it i
; On 20/12/2010 9:03 AM, Jon Olav Skoien wrote:
[ lots deleted ]
> >> Yes, I had it open. In this case it was intentional to give a
> >> reproducible example in case something had changed in the new
version,
> >> in other cases I have had to wait for 2 days bef
On 12/20/2010 1:30 PM, Uwe Ligges wrote:
On 20.12.2010 09:41, Jon Olav Skoien wrote:
On 12/17/2010 6:22 PM, Duncan Murdoch wrote:
On 17/12/2010 11:13 AM, Jon Olav Skoien wrote:
Dear list,
(R 2.12.0, Windows 7, 64bit)
I recently tried to install a new package ("spacetime"), tha
On 12/20/2010 1:43 PM, Duncan Murdoch wrote:
Jon Olav Skoien wrote:
On 12/17/2010 6:22 PM, Duncan Murdoch wrote:
On 17/12/2010 11:13 AM, Jon Olav Skoien wrote:
Dear list,
(R 2.12.0, Windows 7, 64bit)
I recently tried to install a new package ("spacetime"), that
depends on
On 12/17/2010 6:22 PM, Duncan Murdoch wrote:
On 17/12/2010 11:13 AM, Jon Olav Skoien wrote:
Dear list,
(R 2.12.0, Windows 7, 64bit)
I recently tried to install a new package ("spacetime"), that depends on
"sp" among others. I already had the last one installed, but there
Dear list,
(R 2.12.0, Windows 7, 64bit)
I recently tried to install a new package ("spacetime"), that depends on
"sp" among others. I already had the last one installed, but there was
probably a newer version on CRAN, so the command
> install.packages("spacetime")
also gave me:
also installin
On 11/10/2010 11:27 PM, Aleksandr Andreev wrote:
OK, that loads the shape file.
But now when I do:
submap<- subset(spb, as.character(spb$Name) == 'Vasilevsky Island')
the submap still has the whole city, not just the subset. Is there now
a different way of extracting a subset from a map?
I ha
.
On Thu, Aug 19, 2010 at 4:35 AM, Jon Olav Skoien
wrote:
Dear list,
I quite often experience a delayed response when I type in the console of
the RGui of my computer. When typing a command, the text only appears
letter-by-letter on the console if I type rather slow (maximum 1-2 letters
per
Dear list,
I quite often experience a delayed response when I type in the console
of the RGui of my computer. When typing a command, the text only appears
letter-by-letter on the console if I type rather slow (maximum 1-2
letters per second), otherwise it appears some time after I finished
wr
Martin Morgan wrote:
Jon Olav Skoien wrote:
Hi,
I want to cross-reference from the documentation of pkg1 to pkg2, which
is imported in the NAMESPACE of pkg1, and under Depends in DESCRIPTION
of pkg1. According to "Writing R extensions", this can be done by:
\code{\link{foo}}
when
Hi,
I want to cross-reference from the documentation of pkg1 to pkg2, which
is imported in the NAMESPACE of pkg1, and under Depends in DESCRIPTION
of pkg1. According to "Writing R extensions", this can be done by:
\code{\link{foo}}
when foo is an aliased function in the documentation of pkg2.
Hi,
I have already asked a similar question without response
(https://stat.ethz.ch/pipermail/r-help/2009-June/200300.html) so I am
here reformulating in the hope that someone is able to help. If
something is unclear, please ask.
I am working on the development of two packages, pkg1 and pkg2
Hi,
I am currently involved in the development of two R-packages, pkg1 and
pkg2. They should not be dependent on each other, as most users will
only be interested in one of them. Still, I want pkg2 to provide one
extra S3 method for three functions (fun1-3) in pkg1 for objects of a
class def
Maybe
dmat<-dist(dat, method="euclidean",upper = TRUE,diag = TRUE)
can fix your problem with the triangular matrix?
Cheers
Jon
Michael Rennie wrote:
Not really,
I'd actually want
f[4:6,4:6]
to get comparisons of observations 4 to 6 only. And I'm still left
with the upper triangular matrix.
Laura Saltyte wrote:
Hello,
I have data at 10 locations, in each location there are time series
(T=56). Question is: when I’m fitting variogram what happens with those
measures in each location? Are they taken as repeated measures? It's very
important for my to know this
Thanks a lot
Hi La
34 matches
Mail list logo