[Raster-commits] r249 - in pkg/raster: R man

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Fri Feb 6 04:33:37 CET 2009


Author: rhijmans
Date: 2009-02-06 04:33:37 +0100 (Fri, 06 Feb 2009)
New Revision: 249

Modified:
   pkg/raster/R/group.generic.functions.R
   pkg/raster/R/polygonToRaster.R
   pkg/raster/man/click.Rd
   pkg/raster/man/write.Rd
Log:


Modified: pkg/raster/R/group.generic.functions.R
===================================================================
--- pkg/raster/R/group.generic.functions.R	2009-02-06 02:24:45 UTC (rev 248)
+++ pkg/raster/R/group.generic.functions.R	2009-02-06 03:33:37 UTC (rev 249)
@@ -6,11 +6,8 @@
 
 
 .CanProcessInMemory <- function(raster, n=2, datasize=16) {
-#	memalloc <- n * ncell(raster) * 8
-#	memavailable <- memory.limit()-memory.size()
-# For now something simplistic :
-	maxalloc <- 10^7
-	if ( (ncell(raster) * n * datasize) > maxalloc ) { 
+	memneed <- 1.1 * n * ncell(raster) * datasize / 1048576
+	if (memneed > memory.size(max = T)) {
 		return( FALSE )
 	} else { 
 		return( TRUE ) 

Modified: pkg/raster/R/polygonToRaster.R
===================================================================
--- pkg/raster/R/polygonToRaster.R	2009-02-06 02:24:45 UTC (rev 248)
+++ pkg/raster/R/polygonToRaster.R	2009-02-06 03:33:37 UTC (rev 249)
@@ -59,7 +59,7 @@
 
 
 
-polygonsToRaster <- function(spPolys, raster, field=0, filename="", overwrite=FALSE, updateRaster=FALSE, updateValue="NA", trackRows=c(1,2,3,5,10*1:9,100*1:10)) {
+polygonsToRaster <- function(spPolys, raster, field=0, filename="", overwrite=FALSE, updateRaster=FALSE, updateValue="NA", trackRows=0) {
 	filename <- trim(filename)
 	starttime <- proc.time()
 

Modified: pkg/raster/man/click.Rd
===================================================================
--- pkg/raster/man/click.Rd	2009-02-06 02:24:45 UTC (rev 248)
+++ pkg/raster/man/click.Rd	2009-02-06 03:33:37 UTC (rev 249)
@@ -12,22 +12,17 @@
 }
 
 \arguments{
-  \item{object}{A RasterLayer}
+  \item{object}{RasterLayer or RasterStack object}
   \item{n}{number of clicks on the map}
   \item{xy}{show xy coordinates}
-  \item{type}{see under ?locator}
+  \item{type}{One of "n", "p", "l" or "o". If "p" or "o" the points are plotted; if "l" or "o" they are joined by lines. See ?locator}
+  \item{...}{additional graphics parameters used if type != "n" for plotting the locations. See ?locator}   
   \item{show}{logical. If \code{TRUE}, the bounding box will be drawn on the map}  
   \item{col}{the color of the bounding box lines}    
  }
  
-\details{
-forthcoming
-}
 
-
 \author{ Robert J. Hijmans }
 
-\examples{ 
- }
 
 \keyword{ spatial }

Modified: pkg/raster/man/write.Rd
===================================================================
--- pkg/raster/man/write.Rd	2009-02-06 02:24:45 UTC (rev 248)
+++ pkg/raster/man/write.Rd	2009-02-06 03:33:37 UTC (rev 249)
@@ -31,6 +31,7 @@
 	rasterWriteFormats returns a matrix of the file formats (the "drivers") that are supported.
 
 Supported formats include 
+
 Format
 	Long name
 
@@ -40,7 +41,7 @@
 ascii
 	Arc Ascii format
 	
-	ENVI        ENVI .hdr Labelled
+\item{ENVI}{ENVI .hdr Labelled}
 	
 	EHdr        ESRI .hdr Labelled
 	



More information about the Raster-commits mailing list