geor

Create heatmap with distribution of attribute values in R (not density heatmap)

霸气de小男生 提交于 2020-01-24 05:36:12
问题 Some of you might have seen Beyond "Soda, Pop, or Coke". I am facing a similar problem and would like to create a plot like that. In my case, I have a very large number of geo-coded observations (over 1 million) and a binary attribute x . I would like to show the distribution of x on a map with a color scale ranging from 0 to 1 for p(x=1). I am open to other approaches but Katz's approach for Beyond "Soda, Pop, or Coke" is described here and uses these packages: fields, maps, mapproj, plyr,

Trouble Installing geoR package

我是研究僧i 提交于 2019-12-20 07:29:14
问题 I have just installed R and R studio (version 3.0.1) on my Xubuntu 13.10. I want to use the geoR package. However, when I tried to install it, I got an error: install.packages("geoR") Installing package into ‘/home/.../R/x86_64-pc-linux-gnu-library/3.0’ (as ‘lib’ is unspecified) ... ERROR: dependency ‘RandomFields’ is not available for package ‘geoR’ * removing ‘/home/.../R/x86_64-pc-linux-gnu-library/3.0/geoR’ so I tried to install RandomFields install.packages("RandomFields") ... Installing

Calculate variogram of raster data with NAs in R

别来无恙 提交于 2019-12-13 13:34:11
问题 Summary: I have a raster dataset which contains NA values, and want to calculate a variogram of it, ignoring the NAs. How can I do this? I have an image which I have loaded into R using the readGDAL function, stored as im . To make this reproducible, the result of dput on the image is available at https://gist.github.com/2780792. I am trying to display a variogram of this data and am struggling. I'll go through what I've tried so far: I tried the gstat package, but couldn't seem to get a