Par janikas
(1 rating)
Digg this entry Share this entry on 
Facebook Share this entry on Linked In Share this entry 
on MySpace Share this entry on Reddit Share this 
entry on Stumbleupon Share this entry on 
Twitter Share this entry on email share

Description

This toolbox contains a framework for using R (The R Project for Statistical Computing) in ArcGIS 10. This is the second version of the toolbox. This release corrects a previous bug and contains a new tool that runs logistic regression on discrete datasets. The original tool clusters point features based on their relative proximity and/or attribute values. Please check back after the User Conference as we may release another version that takes your comments from the week into account! Lastly, it is very important that you follow the guidelines in the INSTALLDOC.doc.

Contraintes d’accès et d’utilisation

Téléchargement

En cliquant sur Télécharger, vous reconnaissez avoir lu cette licence et en avoir accepté les termes.
Creative Commons Attribution-Only License

Balises:
 R, Point Clustering, ArcGIS 10, Spatial Statistics, Point Patterns
Ajouté:
04-13-2010
Mis à jour:
04-13-2010
Consulté:
9586
Téléchargements:
3013

Commentaires

Auteur: jevans02 Ajouté: November 7, 2011, 12:57 pm

I looked at your R clustering code and have a few suggestions.

1) R has a port to GDAL through the rgdal package. It is quite a bit more stable using readOGR and writeOGR for handling shapefiles over other S3 methods and is recommended over maptools (which is being depreciated by R. Bivand).

2) It is quite dangerous using the cbind method to join the cluster results back to the sp object. For some reason that way slots work in sp class object the vector is not always ordered to the source data. This necessitates using the rownames as a reliable join vector. A common approach utilizes the match function directly on the dataframe slot rownames.
Given that you have an sp object named “shp” and a dataframe “results”

shp@data <- data.frame(shp@data, results[match(rownames(shp@data), rownames(results)),])

3) The clutsTool package is convenient as a wrapper for various clustering options but it would be prudent to provide cluster fit-diagnostic plots using the pdf function for each of the cluster methods. I would rather see methods for evaluation of a few select cluster methods (i.e., K-mediods, fuzzy C-means) than a large number of options with no methods for evaluation of results. Evaluation of fit becomes quite important when the problem is extended past a pure spatial domain into high-dimensional multivariate space.

4) There are now methods available for handling rasters. The "biganalytics” and “bigmemory” packages have methods for K-means that deal with the entire random field of the input rasters. Using the bigmemory package for clustering you just write a function that coerces between a matrix and raster objects. The raster package allows for prediction of almost any generic S3 predict function. I have written a function that creates a subsample from a raster, runs a cluster model and using rpart predicts the clusters to a new raster.

Auteur: pclinton Ajouté: October 25, 2011, 11:09 am

Ok, I finnaly got the logistic tool to work! I'm not sure exactly what did it but I installed SP3, made sure the instructions were followed for installation of the tool and added the user environment variable. Made sure the paths are explicit and the output tables are dbf files and it worked at last!

Auteur: pclinton Ajouté: October 11, 2011, 2:09 pm

I see alot of questions and Zero answers.
I have not been able to get this tol to function without the errors mentioned. Anybody?

pat

Auteur: aelmore61 Ajouté: September 28, 2011, 9:22 am

I've just implemented my first ArcGIS script tool wrapping R code, and it works fine as a stand alone script, but when I put it into a ModelBuilder workflow, it gets hung up when it tries to access a scratch point file generated in ModelBuilder. Does anybody have any suggestions for why this might be happening or how I might get around it?

Auteur: ebnesom Ajouté: September 23, 2011, 11:28 am

I am getting the same error on both the Logit Regression, and Point Clustering. I wonder if there is a new implementation of defineprojection. That seems to be where it errors. ??

Auteur: jluostarinen Ajouté: September 22, 2011, 1:54 pm

Is this the latest/only samples of integrating R with ArcGIS v.10? Thanks for info.

Auteur: cderolph Ajouté: September 8, 2011, 7:57 am

Hi Mark,

I am trying to run the Logit Regression tool and keep getting an error message that I can’t figure out. I have data from my master’s research that I ran through the tool to test it and see how well the outputs matched my stats from SAS and it worked great. However, I’m trying to run the tool with data from a project I’m currently working on and I keep getting the following message:
: Failed to execute. Parameters are not valid.
ERROR 000732: Input Dataset or Feature Class: Dataset C:\temp\Emrg_Output_CalData1.shp does not exist or is not supported
Failed to execute (DefineProjection).

Failed to execute (Logit Regression (R Version) ).

I saved a copy of my input shapefile as on output shapefile that will store the dependent variable estimates and residuals, but when I run the tool it gives me this error and deletes my output shapefile that I previously saved. I’ve tried running this with all inputs from my project directory (which has a long file path) and C:\temp (short file path). I’ve used multiple tools to convert the feature class that I am using as my input to a shapefile. The only other thing I can think of to that I still need to standardize my independent variables because there are a few negative values in there that I need to get rid of, which I didn’t have in my test data. It just doesn’t seem like the error indicates an issue with the input attribute data.

Any help you could offer would be greatly appreciated.

Thanks!

Chris D

Auteur: kangakola Ajouté: August 2, 2011, 11:54 pm

I am having problems with logistic regression too. When I run it it cannot find the output file. I was able to identify the problem. The scipt is using the defaul file geodatabase in the users profiles as input and output workspace. I don't know why is going to default file geodatabse that is in the user profile instead of using the path that was input by the user? Can some one out there help me with the debuging? Thanks. Faustin. K.

Auteur: rgthurau Ajouté: May 2, 2011, 2:21 pm

mharsalan1: I haven't tried this tool in ArcGIS, but if running from R you would have to send the command: gpclibPermit() to free the gpc license.

Auteur: mharsalan1 Ajouté: April 25, 2011, 7:06 am

Idea is good but it has some issue of geometry processing in R. It starts processing but at the point of gpcLib license authentication it stops working. Is there any solution?

Auteur: astarte Ajouté: April 10, 2011, 4:48 pm

I am having problems with Point Cluster tool. When I run it it cannot find the output file.

Auteur: Ermiasb Ajouté: December 21, 2010, 2:34 pm

This is awsome

Auteur: rosarosae Ajouté: October 10, 2010, 12:05 am

Yes! However, does ir work with ArcGIS 9.3?

Auteur: caminante Ajouté: October 6, 2010, 8:48 am

hallelujah! I thought I'd have to do this from scratch, and am very grateful.
-caminante

Auteur: hy.rs.whu Ajouté: April 22, 2010, 8:43 pm

This is a good idea!

Ajouter un commentaire

Si vous souhaitez poster un commentaire, veuillez Se connecter.