[R] adjacency matrix
Roger Bivand
Roger.Bivand at nhh.no
Wed Oct 22 15:13:51 CEST 2003
On Wed, 22 Oct 2003, Orlando Zacarias wrote:
> Dear R experts,
> I am new to the list and R software. I need to convert arcview file to Winbugs having R has middle package. Got from friends that it is possible following the steps:
> 1. Converting arcview shapefile to "cgm clear text file"
> 2. Downloading "convert.r" to into R
> 2.1 use source("convert.r")
> 2.2 convert("filename_cgm") without the extension.
> But that doesn't work, given the following errors:
> ----------------------------
> R : Copyright 2003, The R Development Core Team
> Version 1.8.0 (2003-10-08)
> R is free software and comes with ABSOLUTELY NO WARRANTY.
> You are welcome to redistribute it under certain conditions.
> Type 'license()' or 'licence()' for distribution details.
> R is a collaborative project with many contributors.
> Type 'contributors()' for more information.
> Type 'demo()' for some demos, 'help()' for on-line help, or
> 'help.start()' for a HTML browser interface to help.
> Type 'q()' to quit R.
> [Previously saved workspace restored]
> > source("convert.r")
> > convert("transf")
> Error in file(file, "r") : unable to open connection
> In addition: Warning message:
> cannot open file `transf.cgm'
> >
> -----------------------------------
This is quite a "narrow" question based on other people knowing that you
are refering to:
http://www.biostat.umn.edu/~yuecui/
and the file you have downloaded from there.
The most typical cause of files not being found is when you are not in the
correct working directory. Use:
> getwd()
to access the directory name, and
> list.files()
to see if the name of your *.cgm file is returned. The key comment in the
web page you must have used is:
"Open Splus or R under the folder in which convert.s is saved"
but even if you start in another folder, you can change the R working
directory using
> setwd("where_I_want_to_be")
or from the File menu.
> Have i done some mistakes?Or i am missing some files?
> Please assist.
> Rgs,
> Orlando.
>
>
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help
>
--
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Breiviksveien 40, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 93 93
e-mail: Roger.Bivand at nhh.no
More information about the R-help
mailing list