On Tue, 12 Jan 2016, Helmut Kudrnovsky wrote:

xml1.R

Typo in:

        if (get("SYS", envir=.GRASS_CACHE) == "WinNat" && nchar(WN_bat)) {

should be

        if (get("SYS", envir=.GRASS_CACHE) == "WinNat"
           && nchar(WN_bat) == 0) {

With this r.roughness.vector is found correctly with the *.bat extension,
for me anyway. The fresh Windows binary package from Winbuilder is here:

http://win-builder.r-project.org/bEws3GQ47oph/rgrass7_0.1-4.zip

-----------------------------------
utils:::menuInstallLocal()
Paket ‘rgrass7’ erfolgreich ausgepackt und MD5 Summen abgeglichen

library(rgrass7)
Loading required package: sp
Loading required package: XML
GRASS GIS interface loaded with GRASS version: GRASS 7.1.svn (2016)
and location: nc_spm_08_grass7
-----------------------------------
execGRASS("r.slope.aspect", elevation="elevation", slope="myslope",
aspect="$
100%
Aspect raster map <myaspect> complete
Slope raster map <myslope> complete

execGRASS("r.roughness.vector", elevation="elevation", slope="myslope",
aspe$
----
Check if input files exist ...
----
Define default output names when not defined by user ...
----
Calculate compass aspect values ...
100%
----
Calculate colatitude ...
100%
----
Calculate direction cosines ...
100%
100%
100%
----
Calculate sum of direction cosines ...
Calculating sum of X direction cosines ...
100%
Calculating sum of Y direction cosines ...
100%
Calculating sum of Z direction cosines ...
100%
----
Calculate vector strength ...
100%
----
Calculate inverted Fisher's K parameter ...
100%
----
Result maps:
vectorstrength
elevation_fisher_1K_3x3
Calculations done.
----

-----------------------------------
execGRASS("r.reclass.area", input="zipcodes",
output="zipcode_larger2000ha",$
Generating a clumped raster file ...
Pass 1 of 2...
100%
Generating renumbering scheme...
100%
Pass 2 of 2...
100%
r.clump complete. 16 clumps.
Generating a reclass map with area size greater than or equal to
2000.000000 hectares...
100%
100%
Generating output raster map <zipcode_larger2000ha>...
-----------------------------------

confirmed, it works now.
great, thanks!


OK, thanks, as I've also made progress on the other problem (using temporary SQLite files for vector transfer under Windows), I've submitted to CRAN. Anyone who installed the 0.1-4 versions for testing will need to install the CRAN version when/if it appears.

Roger





-----
best regards
Helmut
--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Using-GRASS-addons-in-R-on-Windows-tp5244411p5244769.html
Sent from the Grass - Stats mailing list archive at Nabble.com.
_______________________________________________
grass-stats mailing list
grass-stats@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-stats

--
Roger Bivand
Department of Economics, Norwegian School of Economics,
Helleveien 30, N-5045 Bergen, Norway.
voice: +47 55 95 93 55; fax +47 55 95 91 00
e-mail: roger.biv...@nhh.no
http://orcid.org/0000-0003-2392-6140
https://scholar.google.no/citations?user=AWeghB0AAAAJ&hl=en
http://depsy.org/person/434412
_______________________________________________
grass-stats mailing list
grass-stats@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-stats

Reply via email to