Salvaj, Erica wrote:
> Hello
>
> I export a one mode network from Pajek to R, and the former made an .r file
> called PajekR.r, that is actually an script to be run in R
> The problem is that what the file actually does is to set a 0 martrix and
> then assing to each pair of nodes the corresponding values. Since the matrix
> is huge (10.000 nodes) a copy/paste procedure is very time consuming, and I
> guess pretty inefficient. So the question is: are there any way to read
> directly the .r file in R, without copy and paste the sentences of the script
> in the R console?
>
The command you are looking for is source.
If PajekR.r resides in your working directory, it
is as easy as
source("PajekR.r")
Otherwise replace "PajekR.r" with the full path to this file.
An other option would be
source(choose.files())
which fires up a GUI that lets you browse for the file.
HTH,
Tobias
>
> Erica H. Salvaj
> PhD Candidate
> IESE Business School
> [EMAIL PROTECTED]
>
>
>
> This message has been scanned for viruses by TRENDMICRO,\ an...{{dropped}}
>
> ______________________________________________
> [email protected] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
>
>
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.