[R] R with atlas in ubuntu karmic 64

2009-12-01 Thread Jose Quesada
Hi,

I'm trying to install R with atlas in ubuntu karmic 64. I do a lot of
matrix operations so I need performance.

Doing

 grep sse2 /proc/cpuinfo

tells me tha my CPU supports SSE2.
But I don't see libatlas3gf-sse2 in the package repositories.

Also, there seem to be some gotchas on how to install atlas, even the
vanilla one, as described here:
http://thread.gmane.org/gmane.comp.lang.r.general/159634/focus=159867

I didn't understand what Bill Dunlap proposes as a solution.
Has anyone installed R with atlas in ubuntu karmic 64? Maybe writing a
howto on a blog post would be a good idea. If I manage to install it, I
will...

Best,
-Jose
-- 
=== I'm minimizing email (can write w one hand only) so if you have
something that requires a long answer, please mail me a time slot and
tel. number and I'll call you. Thanks for your patience.===
Jose Quesada, PhD.

Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-,
Lentzeallee 94, office 224, 14195 Berlin

http://www.josequesada.name/
http://twitter.com/Quesada

__
R-help@r-project.org 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.


[R] operations on sparse matrices, and dense intermediary steps

2009-10-24 Thread Jose Quesada
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hi,

I'm doing some basic operations on large sparse matrices, for example
getting a row.
it takes  close to 30 seconds on a 3Ghz machine, and shots the memory
usage up to the sky.
I suspect there are dense intermediary steps (which, if true would
defeat the purpose of trying to use sparse representaitons).

As much as I try understanding the hierarchy of Matrix classes, it's a
mystery to me.
Is subsetting sparse matrices memory-intensive? Does it have to do with
features of the language, such as pass-by-value bu default?
Or am I doing something inneficent without knowing?

(Note: example below would only work with 64bit R and lots of memory;
reduce size of matrix 2-3 orders of magnitude for 32-bit R)
## libraries
library(Matrix)


rSpMatrix - function(nrow, ncol, nnz, rand.x = function(n)
round(rnorm(nnz), 2))
{
## Purpose: random sparse matrix
## 
--
## Arguments: (nrow,ncol): dimension
##  nnz  :  number of non-zero entries
## rand.x:  random number generator for 'x' slot
## 
--
## Author: Martin Maechler, Date: 14.-16. May 2007
stopifnot((nnz - as.integer(nnz)) = 0,
nrow = 0, ncol = 0,
nnz = nrow * ncol)
spMatrix(nrow, ncol,
 i = sample(nrow, nnz, replace 
= TRUE),
 j = sample(ncol, nnz, replace 
= TRUE),
 x = rand.x(nnz))
}


## (original ir a term x doc matrix of the entire wikipedia)
mm - rSpMatrix(793251, 1027355, nnz = 205746204)
# make it column based:
mm - as(mm, CsparseMatrix)
a=mm[1,,drop=F]#this takes close to 30 seconds on a 3Ghz machine

Thanks,
- -Jose
- --
=== I'm learning a new keyboard layout. I type slowly. Please excuse
typos and slower-that-usual responses. Thanks for your patience===
Jose Quesada, PhD.

Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-,
Lentzeallee 94, office 224, 14195 Berlin

http://www.josequesada.name/
http://twitter.com/Quesada

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.9 (MingW32)

iQIcBAEBAgAGBQJK43ZUAAoJEGMobUVGH+HKsZEP/1+R/x2Qv9Kc1LYNP01Hvirz
n8ZVz/fGm+uCt/n4F+cXdXntZ3yoUVZcPy7LwMIo5W4x/saS5cMjBg6Z8hsDvXEQ
2KiiPYJ46C6hEOGJwrpYfOZwm7t5aIMMhaP182P19ziKhpp/Gn4joTnXUzigNHzt
vIPBOBgdZdPvC0h9ByvtCmMSX3roQPv1nMIojrPC0+EzfIVVNIcsfQYYacOyhcuM
/RR97aOzHvcdCln7FbrIT2I0SeeVH3scFGN7q7KFi6Sy+KZmQsv7FxfnUAvf5R+l
DAcm0ekeThksSmJE/Td1220ZguaORjyMHwAKfJH+wiXei24+N+Xf22469g2gCEWb
hiNUzhLHXOSY6mKZ80LKMbhUM4JhKs7K1HImwQmVDa/1UU1WwsjrzZ2fHHqnsjQi
Uysrttu1nbTT5Yvn9CT8gedM7A78sIddjpi1PavbRVJl7/eDN5PGgwilQ70DNetJ
PY8QvLGlA4GGtdvTzxFVP2VK0QgfxmRedrEwqxR1AlIZRn9iK8jrZCXTGLeXe5LX
BX7PQXs11ZfuW/kzDBstqobCrxSERRb/HP5BlY+mKmZ0SieoVkpLeJ7PdeHu+r31
8bsZPkeHaO5MR1KrG155JOK1vgmHPpfSiq0lNUT99hncoFKBvweDnE3Etx+tBra7
h9lxbDeHl6xkbCJj/LDb
=ZVWO
-END PGP SIGNATURE-

__
R-help@r-project.org 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.


[R] dgTMatrix --- [, , drop=F] strange behavior, Matrix 0.999375-20

2009-10-22 Thread Jose Quesada
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hi,

I have something strange here...
I want to subset a large sparse matrix, with the subset being still in
sparse form. Easily achievable with mm[i,,drop=F] , right? Well, it
doesn't work on the matrix I'm working on.

This is a very large wikipedia Matrix (now I can play with it as I just
got 16Gb of memory):

 m...@dim
[1]  793251 1027355
 nnzero(mm)
[1] 205746204
 class(mm)
[1] dgTMatrix
attr(,package)
[1] Matrix

Imagine I want just the first row:

 a = mm[1,,drop=F]
 length(a)
[1] 1027355
 nnzero(a)
[1] 1291
class(a)
numeric

However, _a_ is just a numeric (dense) vector (!). This takes a long
time and a big bite off my memory.
This is NOT what I get when I play with a toy example. In this case it
works as expected:

 (m - Matrix(c(0,0,2:0), 3,5))
3 x 5 sparse Matrix of class dgCMatrix

[1,] . 1 . . 2
[2,] . . 2 . 1
[3,] 2 . 1 . .
 a = m[1,,drop=F]
 a
1 x 5 sparse Matrix of class dgCMatrix

[1,] . 1 . . 2

I wonder if it's a matter of size:
 M - kronecker(m, diag(1))
 a = m[1,,drop=F]
 class(a)
[1] dgCMatrix
attr(,package)
[1] Matrix

Looks like it's working as expected on a sizeable example. What could be
going on? What's the difference between mm and M, (other than size?).
I'm not sure this is enough info to reproduce the problem (i.e., the
example matrices I posted work, mine doesn't). The problematic matrix is
.5gb compressed as .Rdata, so it's not easy to send it around.

This is  0.999375-20, not the latest version as of today: 0.999375-29;
however it's the only one available in the revolution 64 repositories
(win64).

Any idea what to try next? I cannot afford to operate with dense
representations.

Best,
- -Jose
- --
=== I'm learning a new keyboard layout. I type slowly. Please excuse
typos and slower-that-usual responses. Thanks for your patience===
Jose Quesada, PhD.

Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-,
Lentzeallee 94, office 224, 14195 Berlin

http://www.josequesada.name/
http://twitter.com/Quesada

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.9 (MingW32)

iQIcBAEBAgAGBQJK4NwwAAoJEGMobUVGH+HKqccQAIiT+7642HI56OWvfN9OqriK
5QsimU8tyaHwYn6Xlb6wx1Da2uBKpMBz9AfSHOO12xIr5Irm3DtHKPTjkGS3QV9P
kYb1zUA3b5iZrFOj6hgChs4m6xx1MmsAwpG7Ft1oLXKY9/SF+Yqt4OoUHqRsNaI1
m+SpjZLEu8QKfq0F7FGVCJ8sGPMJ8E7nOq7qcRHQ3eIOcUoKZ0bFZrixDxD9oH02
enX4cqcHGJFiS27e70IIBoh4Q8mG96Z9LLm7/EbFdJMyWyzJQDVcBL+o/UUYjmTi
AxMUQjfFf2/2nDz6mFJ3raU0AS6vLuliq1/B2K52znJxqa+GT9pNc7l79OTVa1oc
F6BUBuAPj+1UQX1xO4lG6yjNoN1KZKmyoE/5tWnvWnp9tSxmszlty7f86/fpx3Mz
44dvLOcuucTUTLOdvkT9rSqWXS9M3GdS+kH5qD5RVd4ONw54iv4K3kxGfmmyb+6K
b19DbP7sVMe8qgybYLAyuPmeOskWbcRh/glkRrXV642NoiQVtu1UcIiGoNPxpAF4
Qu5bHIRCvkayUVbxFuqNo3xHEaTdvTX5IqzlseVpDYOKkRv3SJeiLGfZgnUvH0wG
zL5BIYBPXhtQjysL69VSyWs4mASUwZ0N5WhhWWTFVSnG+p1QS+CNURWwXYVTpvos
9kEvQ45lcQEKJ1bNuPBm
=XUeB
-END PGP SIGNATURE-

__
R-help@r-project.org 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.


Re: [R] R on Linux, and R on Windows , any difference in maturity+stability?

2009-10-06 Thread Jose Quesada
Robert Wilkins iwritecode2 at gmail.com writes:

 
 Will R have more glitches on one operating system as opposed to
 another, or is it pretty much the same?
 
 robert
 
 

One important difference is that, if you are unsing large datasets and need
memory, then windows is by far the worst. 
CRAN R is 32 bit and can only address 1.5 Gb of memory (or something similar; I
don't really understand why).

While there's a 64-bit version of R for windows (revolution-computing.com) I
would advise against using it, for several reasons. While revolution has
provided very nice packages to the community (e.g., foreach), the win-64 port as
of today is certainly the worst platform to do work on. Reasons:
(1) it's R 2.7.2
(2) Many important packages will never be ported
(3) Some packages (particularly those depending on Rjava) would not work 
properly
(4) There's a proprietary repository, where most packages are outrageously
outdated. 
(5) Most help you find on R-help will not apply. Instead, you have 'paid'
support. Said support is slow, and close to useless in most cases.
(6) Packages that rely on external tools (e.g., mysql) will take a lot of work
to get going. 

And of course, one have to pay for a yearly license, to have the privilege to
work under the above conditions.

If you need 64-bit right now, my advice is to switch to basically any other
platform.

Note: this may change any time, since they are working on a continuous build
that will keep the releases in sync with mainstream R.

Jose Quesada, PhD.
Max Planck Institute, Human Development, Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] Scrolling behavior in View()

2009-06-07 Thread Jose Quesada
Hi,

I've realized that the scrolling behavior in View() is unlike most other
applications. It seems that the minimum scroll size is very large for
large objects( i.e., a vector of 1M integers), and it might be that this
scroll is proportional to the size of the object.
Try this:
a = 1:100
View(a)
Click once on the scroll arrow down. It will move to item 1001.

It could be that the scroll size is 1/1000 object length.

If this is so, it's a bit of a problem, since there's no way to View say
cell 500... unless one does a View(head(a, 500)), which kind of defeats
the point of view.

Is this behavior by design? If so, wouldn't it be better to make it
optional (as it breaks GUI conventions of mostly any OS for scrolling
behavior)? An argument for view to turn this off would be great.

Thanks!

Best,
-Jose

-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


Re: [R] a simple trick to get autoclose parenthesis on windows

2009-05-31 Thread Jose Quesada
Gabor Grothendieck wrote:
 Hi, I was looking for your sendcodetoR.ahk autohotkey script
 but couldn't find it.  Would you be able to point me to it.
 Thanks.
   
Here's what I have right now, it also maps right alt to send code to R.
You should change the ahk_class to your editor of choice (here it's
vim). To get the ahk_class, you need to run the atoit_spy (comes with
every autohotkey install).

HTH,
-Jose

; F3 and right alt will send selection to open Rgui
#WinActivateForce
F3::
IfWinExist, ahk_class Rgui
{
Send ^c; copy selection to clipboard
WinActivate ; R Console
save = %clipboard%
sendinput, {Raw}%save%
sendinput,{enter}
Sleep 1000
WinActivate, ahk_class Vim
}

Ralt::
IfWinExist, ahk_class Rgui
{
Send ^c; copy selection to clipboard
WinActivate ; R Console
save = %clipboard%
sendinput, {Raw}%save%
sendinput,{enter}
Sleep 1000
WinActivate, ahk_class Vim
}
return


-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] alternative to built-in data editor

2009-05-27 Thread Jose Quesada
Hi all,

I often have to peek at large data.
While head and tail are convenient, at times I'd like some more
comprehensive.
I guess I debug better in a more visual way?
I was wondering if there's a way to override the default data editor.
I could of course dump to a txt file, and look at it with an
editor/spreadsheet, but after doing it a few times, it gets boring.
Maybe it's time for me to write a function to automatize the process?
I'd ask first in case there's an easier way.

Thanks!
-Jose

-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] a simple trick to get autoclose parenthesis on windows

2009-05-27 Thread Jose Quesada
Hi,

This is a simple trick to get autoclose parenthesis on windows.
If you like how StatET autocloses parens, but like to use the lighter
Vanilla R, you can use autohotkey (http://autohotkey.net) to provide
this functionality.

Simply put the below code in a text file, rename extension as .ahk and
doubleclick on it to execute.


-- code starts here 8 --


; Vanilla R
; =
#IfWinActive, ahk_class Rgui
; autoclose parens
(::Send (){left}
::Send {left}
return

-- code ends here 8 --

Silly, but I find it very convenient.

Best,
-Jose

-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


Re: [R] Vim R plugin-2

2009-05-09 Thread Jose Quesada
Jakson A. Aquino jaksonaquino at gmail.com writes:


 Dear R users,

 People who uses vim in Linux/Unix may be interested in checking the
 plugin for R that I'm developing:

   http://www.vim.org/scripts/script.php?script_id=2628

 The plugin includes omni completion for R objects, code indentation
 and communication with R running in a terminal emulator (xterm or
 gnome-terminal). This last feature was already present in Johannes
 Ranke's plugin.

 I would like to know if you have any suggestions of improvements.

 Best regards,



Excellent work!
I wonder if this could be made more portable (e.g., it depends on perl, + R
being on a tty terminal, which is not always the case).

I'll try to look at it and see if I can port it so it works on windows.
But the
current communication method I use there are just the clipboard, not sure if
it'll be possible.

Any alternative ways of sending info both ways from R to any open
process (vim)
in windows?

I have, and like, perl; the only think that is missing is the tty support on
windows (I think!)

-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


Re: [R] Vim R plugin-2

2009-05-09 Thread Jose Quesada
Jakson Alves de Aquino wrote:
 Jose Quesada wrote:
   
 I'll try to look at it and see if I can port it so it works on windows.
 But the
 current communication method I use there are just the clipboard, not sure if
 it'll be possible.
 

 Unfortunately, I cannot help on Windows environment.

   
 Any alternative ways of sending info both ways from R to any open
 process (vim)
 in windows?
 

 Netbeans could be a fast and portable route for communication between R
 and vim without the need of using either pipes or files saved in disk as
 intermediary. Typing :help netbeans in vim should show netbeans
 documentation. R also has TCP support: write.socket(), read.socket(),
 etc. We could begin to explore this route...

   
Great finding!
I wish I had more time to dedicate to this.

Have you seen:
http://pyclewn.wiki.sourceforge.net/features+

In my view, R as a language is very good but the tools around it are not
good.
When a matlab person tries R, their first comments are always how poor
the environment is.
Sure, one can have a debugger (with a crappy GUI in TK), and there's
some editor support, but it's kind of painful.

Integreting an R debugger with something like pyclewn would be very good.

Best,
-jose


-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] Rmysql linking to an old-ish mysql build

2009-05-08 Thread Jose Quesada
Hi,

I'm trying to get Rmysql to work o windows server 2008 64-bit.
I have the latest build of mysql installed (mysql-5.1.34-winx64).

When trying to load Rmysql, I got a warning that Rmysql is linking to an
old-ish mysql build (5.0.67).
I could do some basic stuff (the connection works) but it breaks when
trying to read a large table.

So I set up to use the buld 5.0.67 that Rmysql likes.

10 hrs later and after lots of sysadmin work, I have to call it quits. I
couldn't make it work.

Since this mysql 5.0.67 is pretty old, I was wondering if anyone has
binaries for Rmysql that work for a more recent version.
Maybe the authors of the package have plans to update it soon?

I've tried the package on both R 2.9.0 and R2.8.1.

If nothing comes up, I'll try to spend a few more hours on getting the
old version to work.

Thanks!

Best,
-Jose

-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] RMySQL and non-installer mysql

2009-05-06 Thread Jose Quesada
Hi all,

I'm running mysql on windows server 2008 64, but I just unzipped files.
There's no installer and no registry entry.

When using RMySQL, it seems that it needs to look at the registry:

 library(RMySQL)
Loading required package: DBI
Error in utils::readRegistry(SOFTWARE\\MySQL AB, hive = HLM,
maxdepth = 2) :
  Registry key 'S' not found
Error : .onLoad failed in 'loadNamespace' for 'RMySQL'
Error: package/namespace load failed for 'RMySQL'

Thus, it finds nothing.

Is there any workaround?
Thanks!

-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] How do I set the working directory when using ESS and R under windows?

2009-04-30 Thread Jose Quesada
Hi,

While I'm a devoted vim user, I'm testing ESS :)
How do I set the working directory when using ESS and R under windows?
When I try to launch R, it asks for a directory. In windows, it simply
doesn't let you pick a directory on the 'open' dialog.
It may be a problem with windows server 2008 64 bit, though, as it seems
really basic. Thanks.

Best,
-Jose

-- 
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and Cognition -ABC-, 
Lentzeallee 94, office 224, 14195 Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] dpaste, pastebin etc. Syntax highlighting for R?

2009-03-16 Thread Jose Quesada
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
 
Hi All,

There are many sites to get bite-sized chuncks of code.
The nice thing is that they use syntax highlighting.

Examples:
http://dpaste.com/
http://pastie.org/
http://pastebin.com/

Twitter with a link to a syntax highlighting site would do wonders.
There are plugins for most (good) editors to post directly to the site
from the editor.
Example:
http://www.vim.org/scripts/script.php?script_id=1624

The wiki shows that there are good working solutions to get R syntax
highlighting coverted to html.
The code for such a thing is here:
http://www.andre-simon.de/

Does anyone know of any of those pastebin-like sites that uses
R-friendly syntax highlighting?

Hmm, I had another idea, but maybe I'll use an independent thread.

- -Jose

- --
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and cognition,
Berlin
http://www.josequesada.name/   
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
 
iQIVAwUBSb6OIGMobUVGH+HKAQI5kQ//cpxdTFSEskP1M1bOCYWBVOYlsnBxxNAt
lg/N3AMk1dpDNWXkhVi8GPrnfjjh76rT2XAVkbNr/uu0iRDsucsFFmHF2C6zXYPm
cwpIMlEfY+rWdyEdUq3AayTYviHlp4HQWIXRLJX7B35auUwMORXN5KS1i+djo+Lh
OnTQqFc8adZakjHUy347YZxfT4l0iaAA+UdJB1Q6JQWLM2CiIPRwe7EOh6fZeUVU
02NQbkFVim+iMmTk8K+ZRU3NZUigBaJ9utFxJV1N5sosPtRmRSG+YhdvpI99JSTW
uhSX0LlyqEkzAsDLFjXOF7ZWyWEGqRKEf51Z+4YCw3Dgzbn7TkCw/FozNaSXHZOx
mms+rngUftSR1Q58bZVbx5WQwqD3Jbujqu0DsFmcNNP5220vYbaJ7r7Ei56WFzuG
ShJgP7JkdejQRDFNYDF/BtHGkbaXFD8su75DSwYA3bNr6DBFbC1taE3nuV5X++IH
qonlrrR/1pCAskQwpWIKUqfLyDhDjJD5tTYDylg+yPkncoBOFBMo+BvMk4faas4b
KGxUdVqeOSGolXoN2m1P2lUOKjy6pOVsYuZQUSCZRH3tK5prkEMhGmSdLtCdjnjC
vbEkhy4i9qSZOKmITLsBjk0Tx5z0RuN3xlcs1moYF7EXjJIXYQlHFsfAQqqIAxAC
SdYl6u/1Jx0=
=r7BH
-END PGP SIGNATURE-

__
R-help@r-project.org 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.


[R] R-code in html help pages: syntax highlighting

2009-03-16 Thread Jose Quesada
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
 
Hi,

A follow up to my previous post. It'd be good to have syntax
highlighting in the html help pages. There is highlight
(http://www.andre-simon.de/) which seems to be open source. Since code
is delimited in the help file format, it should not be too difficult
to run a highlighting program (actually, vim and emacs do this too)
recursively and pretty-print all the R examples in the entire CRAN.
Including the highlighter with R, or whatever supplementary tools
people use to make R html help files could simplify things. I've never
written docs or released a package, so I may be understimating the
effort it'd take to get this working.

Using the r-help gmane archives also leads to plain code.
This is probably more trouble than it's worth, since there's no
metadata delimiting a block of code and it might be difficult... but
grepping through all R-help posts and coloring code would be really
nice too. Again, this lands straight into 'nice to have, but not
essential' territory.

If anyone wants to do this, feel free to.

Best,
- -J

- --
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and cognition,
Berlin
http://www.josequesada.name/   
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
 
iQIVAwUBSb6RRGMobUVGH+HKAQI2RxAAijNIj7qlBogc9M6lhQ2Ah1Px29iU/uzS
45t5blwNSGVSbAbZF7N7rRcBdn8/c4W8n+oI62nnap0snwLMFW/ynikVNJuBY+XA
+yNaO5nIJo5SWu60WkcMinm/ysPZ4o4Jdxr1+lGfJ/ceVSTWPWVLb//GN8QElgwT
Vf0ZQUSqfWczzeVDSDtfMKGTJOz4y60eF5hounA/PkzyUd8RRo1WpEXzJHYsCTI+
RwBrYZ5Q30cpKLAJQNeiiv8GDtv7QvJl38uRAqBRK5Ec9CGC0brGZquX8UgHi1q1
1+NzHSt95E4Y0CKWPS48t+eO58MUE8v69gjLa9DdnhII4tCdAUURuP+AsaFm+hzP
a7OufMNnh/S8igDmqon0c9W6sJrkDo9DdrZPlu6MFjGQ5SbS6mSfvwSRKVd3RTCN
2/+uz0EwBygq1OKS+Z7Z+kx29UR8+bNXOGaPRlsr5CKcwVV9w3FBvEICuDaP75vj
l0d75+2R+CB/R/e2+dMMRCQY5MNWtYuuqoz3jNws59J+0z5K35usLoaKdB7Ez3D6
G2CCBKJSrugT0s8OkhX5pcTiU6NUIrq6q8h7JNEeuR0bniFClXlDrAs9iIdNb4PS
oFpqtNJWPLaicHRMnJdnxPCriHa0lmI3QVoGrf6UFtBAXuiOkFxcHUmTcQczyfOm
IGyGcgCko3o=
=djsT
-END PGP SIGNATURE-

__
R-help@r-project.org 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.


[R] Comparison of data analysis packages: R, Matlab, SciPy, Excel, SAS, SPSS, Stata - Brendan O'Connor's Blog

2009-03-14 Thread Jose Quesada
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
 
Hi All,

I found an interesting thread discussing R and other packages here:

http://anyall.org/blog/2009/02/comparison-of-data-analysis-packages-r-matlab-scipy-excel-sas-spss-stata/


Plenty of well-reasoned comments.
I thought it may be informative for people on this list.
Best,
- -Jose

- --
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and cognition,
Berlin
http://www.josequesada.name/   
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
 
iQIVAwUBSbvhbGMobUVGH+HKAQKVzg//T3FOXQYSoTaqs5dHeu6V8fyTjmHYPmKZ
TyDbXTBVJqs8cQiP0fc1V2pq0r8CAdj4NTRsSpO2XKVUSF8TSa7/8afhlFk8WzDW
8pGVC+PWTJhYJmZbnG06+sNtiv586DwOx1cBnMW6xJ/1jiWWykDQrQLKoidBDYxM
b1yFdezu7+PsKNO7eyymceGf3No1bYtcxpjB82JkcmUK+13eriZOtILXEntCPgpf
a0q48NRKhluMzpSt8mjyKnFUIOZ6fPbDyUWAdQdAwU6Gh6Pkfe8entW+yzzSJnDL
GUlhJNBNUjhNfaogcBJjnyrrVU0XvMrAW5t3GSMZd3ItIHuPS1TdOIndtEsohYjB
DPXLcpbdgjxBvfVVobVxaAQ5tITH0Wd0AFdQVKUW9N7ThtiRK7Y3EfyGnx4NIRIl
9TWLc5L2TBCJHJeYGZCNwDBS0MHjJMcggcCFcvWfJUlU17YDiUP5TqA3UbJY4roB
JIjGrWx8aOU88Wdw15lU6j5yWIJUvbHfjc69R0QsdgSnf6XpGOO+7IsxVufZLN9j
fdAA2ydSY2aZYIg9gli/S1n5DjmF/aJOLtePWXYZ79ikoheiGn8CQAgYZi7muPvR
kI2pv9HR9YNGnfI4qcA/YkgzFVSktdy/anMQQ+6D2LeMMJYEwOF2y6KXSevNDbl5
kNesp3BYlZs=
=cFnL
-END PGP SIGNATURE-

__
R-help@r-project.org 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.


[R] using chm help files under linux

2009-03-10 Thread Jose Quesada
Hi,

Chm (compiled help) is a microsoft invention. It's the default help
system under windows, but not so under linux.
I found that (at times) I like better how chm help looks.
Since there are chm viewers under linux, using chm help files should
be possible.
Has anybody tried to set R so it opens chm by default? I'm sure
there's some flag or Rprofile var that could get this done.

Thanks,

-- 
-Jose
--
Jose Quesada, PhD
http://josequesada.name

__
R-help@r-project.org 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.


Re: [R] R and vim (gvim) on ubuntu

2009-03-06 Thread Jose Quesada
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
 
 when I try to run an R command eg, x - rnorm(100,10,5) vim returns this
 error:
 ~/.pipe E212: can't open file for wirting

Hi Andreas,

I'd recommend to use this script instead. It uses screen to
communicate R and vim, it works well.
http://www.vim.org/scripts/script.php?script_id=2551

Best,
- -Jose

- --
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and cognition,
Berlin
http://www.josequesada.name/  
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
 
iQIVAwUBSbG4b2MobUVGH+HKAQLovRAAv/X2tRiZwRB6m+MCLG1wuBDyR5mVDmIH
Ox+yrWxusxS+5ezHjasR9usVsF6PxN7C+mK9zdeFQhxrO93F8dDsCvW1B+Qq51f4
s6+lY9pPmn7SKTfIpr6PlkvLVf38y++yMLvqMCnXfu+PXENe6degY+KEtykCbQDa
/gtE00zu/RYY5VslJj3/DQncJjBR7zvmyDkVTKZA7j4BTKlP6N48JDRgjd1IThrd
oyUVV4JM87Sy/1rqx1/WXVV6F+9fcmRV/nF9RWjFyNaT8ILlNlrhHR6EtDj8mz0h
vUs831YxUWu4o9aaioZsbMNAFQRX9uyUf+LjXj7TyRlznJgQ7ih+HJmOb7/dJD4d
vQpgFQUNU31+oYwk75zvtO8tSqNsUp5qHBaZ8dSZjCEoSGARSRukhtyfLK92VrCz
2J9aSajOFUZ4/HKsu+1TJhYjOcZXgFXJo8qUQPKBt973t3N7lvIlE9/F/rq7u8Si
eC5tyrm6LyUNXKKbjaS9jOyXBWfI+P3zj+i3Qo/2nmetegtmgNxYuTJlu8DFtiik
gPS+BDXycrw2f8jOOJxZJ/25nsynTFQh6rAy89ZAu7GqeVFsJlwe5Gh7M64xAflG
vhmnpESTFhVEGxu+CC71/PO1imbd69WDE69drF9UxTHQ7Bp6mGhI4E/1+0uXgCfN
6fJVnAMdJ9w=
=iPvx
-END PGP SIGNATURE-

__
R-help@r-project.org 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.


[R] Working with RDF

2009-02-09 Thread Jose Quesada
Dear list,

I will be working with RDF in the future, and was wondering if there's
anyone else in this list doing this.
Any libraries/resources to check?

Thanks,
-Jose

-- 
Jose Quesada, PhD.
Max Planck Institute, Human Development, Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] twitter useRs?

2009-02-09 Thread Jose Quesada
I wonder if there are any useRs sharing day-to-day realizations/tricks
on twitter...
Seems like a good place for those things that are good findings, but
one is too lazy to blog about them...

-- 
Jose Quesada, PhD.
Max Planck Institute, Human Development, Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] Test Driven Development in R

2009-01-31 Thread Jose Quesada

Hi,
I wonder what kind of interest there is on Test Driven Development (TDD) in R.

Test Driven Development consists of writing the test before the function, and 
iteratively build the function until it passes the test.


Python and Ruby (specially Ruby) have very strong test-oriented cultures. In 
fact, in Ruby at least the custom is to do TDD and lately Behavior-driven 
development (BDD). In BDD, one writes a story of what one would want the code to 
do. This story is almost native English, and then the test suite converts it 
into something that the language understand as tests.


There are some posts on the list about this, but they are about testing in 
general (Runit), not TDD. Example:

http://thread.gmane.org/gmane.comp.lang.r.general/85047

Recently, I found there is an alpha, but working implementation of TDD for 
Komodo edit:

www.sciviews.org/SciViews-K/index.html

The editor has a green bar that becomes red as soon as one edits a function, and 
that edit breaks the tests. This is tremendously useful.


Using Gmane search, the only mention I could find on svUnit was:
http://thread.gmane.org/gmane.comp.lang.r.general/136632/focus=136662

I think this could make a great UseR 2009 talk. Ideally, by someone with more R 
experience than me, and even more ideally by Philippe Grosjean :), but it push 
comes to shove, I could prepare such a talk.


Would this be interesting at all? Are there any resources that I have missed? 
How many people are using this kind of testing or Komodo -sciViews at all?


Best,
-Jose
--
Jose Quesada, PhD.
Max Planck Institute, Human Development, Berlin
http://www.josequesada.name/

__
R-help@r-project.org 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.


[R] R vs Python performance-wise

2008-12-06 Thread Jose Quesada

Hi,

Has anyone run any R vs Python (numpy) tests?
I'd love to see what the differences performance-wise are, specially  
handling large sparse matrices.
Since both rely on external C code, there might not be much of a  
difference.


If you know and use both languages, what are the main differences and what  
made you stick to one over another?


I also noticed that there are strong libraries for social networks on both.

python:
networkX: https://networkx.lanl.gov/wiki
pySNA: http://www.menslibera.com.tr/pysna/

R:
sna, network etc. see:
http://www.jstatsoft.org/v24

Has anyone run a bechmark of the two systems doing the same operation?

Which is the right environment for large social networks? Some packages  
have bindings for both languages, and of course, there's  a reliable way  
to bind the two languages together, Rpy:

http://rpy.sourceforge.net/

So this may not be a big deal which one to pick.

Thanks,
-Jose

--
Jose Quesada, PhD.
Max Planck Institute, Human Development, Berlin
http://www.andrew.cmu.edu/~jquesada

__
R-help@r-project.org 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.