[Rd] newline with cell of Excel worksheet created with write.xls

2007-02-08 Thread Mark W Kimpel
As part of my project to put different types of results into worksheets, I would like to be able to put an auto-generated methods section. If I compose in RWinEdt, read into R, and use write.table with a .txt file extension, what I get out has line-breaks that correspond to those I put in in th

[Rd] append within worksheet in write.xls

2007-02-08 Thread Mark W Kimpel
I can currently append an entire worksheet with write.xls, but would also like to be able to append within the same worksheet. Is this possible? It doesn't seem to work if I use append = T Thanks, Mark -- Mark W. Kimpel MD Neuroinformatics Department of Psychiatry Indiana University School of

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Mark W Kimpel
Gabor, What I want is a bit more than hyperlinks, although I did ask the package developer about that to. My idea is, from within R, place things like pdf files and .Rdata directly into an Excel spreadsheet. As a practical matter, if I can create a report with some data that someone else can m

Re: [Rd] Problem using ofstream in C++ class in package for MacOS X

2007-02-08 Thread Paul Roebuck
On Thu, 8 Feb 2007, Ross Boylan wrote: > On Thu, Feb 08, 2007 at 11:53:21PM +0100, cstrato wrote: > ... > > >Maybe there's some subtle linker problem, or a problem with the > > >representation of strings > > > > What do you mean with linker problem? > > > Nothing very specific, but generically wro

Re: [Rd] obscure error with subsetting as.list() of a function then (PR#9504)

2007-02-08 Thread p . dalgaard
[EMAIL PROTECTED] writes: > Hello. I was writing some code that computes on the language and came acr= oss > this. I can work around it, but thought you might like to know about it. > >> f <- function(x) { NULL } >> a <- as.list(f)[[1]] >> a # ie print(a) > Error: argument "a" is missing, with no

Re: [Rd] Problem using ofstream in C++ class in package for MacOS X

2007-02-08 Thread Ross Boylan
On Thu, Feb 08, 2007 at 11:53:21PM +0100, cstrato wrote: ... > >Maybe there's some subtle linker problem, or a problem with the > >representation of strings > > > > > > > What do you mean with linker problem? > Nothing very specific, but generically wrong options, wrong objects/libraries, or wro

Re: [Rd] obscure error with subsetting as.list() of a function then assigning that a (PR#9500)

2007-02-08 Thread Peter Dalgaard
[EMAIL PROTECTED] writes: > Hello. I was writing some code that computes on the language and came across > this. I can work around it, but thought you might like to know about it. > >> f <- function(x) { NULL } >> a <- as.list(f)[[1]] >> a # ie print(a) > Error: argument "a" is missing, with no de

Re: [Rd] obscure error with subsetting as.list() of a function then assigning that a (PR#9500)

2007-02-08 Thread Gabor Grothendieck
Also note: missing(a) # TRUE On 2/8/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > Hello. I was writing some code that computes on the language and came across > this. I can work around it, but thought you might like to know about it. > > > f <- function(x) { NULL } > > a <- as.list(f

[Rd] obscure error with subsetting as.list() of a function then assigning that a (PR#9500)

2007-02-08 Thread peter-m . schumacher
Hello. I was writing some code that computes on the language and came across this. I can work around it, but thought you might like to know about it. > f <- function(x) { NULL } > a <- as.list(f)[[1]] > a # ie print(a) Error: argument "a" is missing, with no default Note it says *argument* "a",

[Rd] wheel ownership of new documents: OS X, (PR#9499)

2007-02-08 Thread wd213355
Full_Name: William Doane Version: R version 2.4.1 (2006-12-18) R.app GUI 1.18 (4038) OS: OS X 10.4.8 Submission from: (NULL) (72.228.26.7) If one creates a new document within R.app and saves it, the group ownership is set to wheel, rather than the users' personal group: -rw-r--r--1 wejdoane

Re: [Rd] Problem using ofstream in C++ class in package for MacOS X

2007-02-08 Thread cstrato
Ross Boylan wrote: > On Thu, Feb 08, 2007 at 10:04:14PM +0100, cstrato wrote: > >> Ross Boylan wrote: >> >>> On Sun, Feb 04, 2007 at 10:47:37PM +0100, cstrato wrote: >>> >>> Seth Falcon wrote: > cstrato <[EMAIL PROTECTED]> writes: > >

Re: [Rd] Problem using ofstream in C++ class in package for MacOS X

2007-02-08 Thread Ross Boylan
On Thu, Feb 08, 2007 at 10:04:14PM +0100, cstrato wrote: > Ross Boylan wrote: > >On Sun, Feb 04, 2007 at 10:47:37PM +0100, cstrato wrote: > > > >>Seth Falcon wrote: > >> > >>>cstrato <[EMAIL PROTECTED]> writes: > >>> > >>> > Thank you for your fast answer. > Sorrowly, I don´t

[Rd] One possible use for threads in R

2007-02-08 Thread Ross Boylan
I have been using R on a cluster with some work that does not parallelize neatly because the time individual computations take varies widely and unpredictably. So I've considered implementing a work-stealing arrangement, in which idle nodes grab tasks from busy nodes. It might also be useful for

Re: [Rd] Problem using ofstream in C++ class in package for MacOS X

2007-02-08 Thread cstrato
Ross Boylan wrote: > On Sun, Feb 04, 2007 at 10:47:37PM +0100, cstrato wrote: > >> Seth Falcon wrote: >> >>> cstrato <[EMAIL PROTECTED]> writes: >>> >>> Thank you for your fast answer. Sorrowly, I don´t know how to use a debugger on MacOS X, I am using old-style pr

Re: [Rd] Problem using ofstream in C++ class in package for MacOS X

2007-02-08 Thread Ross Boylan
On Sun, Feb 04, 2007 at 10:47:37PM +0100, cstrato wrote: > Seth Falcon wrote: > > cstrato <[EMAIL PROTECTED]> writes: > > > >> Thank you for your fast answer. > >> Sorrowly, I don´t know how to use a debugger on MacOS X, I am using > >> old-style print commands. > >> > > > > You should be

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Vladimir Dergachev
On Thursday 08 February 2007 2:09 pm, tshort wrote: > I don't know of an R package that has a function to encode files as a > multipart mime, but the link above is a good start. Tclib has mime encoding module one could use it from within R with .Tcl("package require tcllib")

[Rd] supsmu(periodic=TRUE) can crash R by reading before start of array (PR#9502)

2007-02-08 Thread bill
supsmu(periodic=TRUE) can crash R by reading before start of array. To reproduce: set.seed(1) xx <- runif(29000) yy <- rnorm(29000) span <- 0.49 i <- 1 while(i < 200){ cat(i,"\n") int <- supsmu(xx,yy,periodic=T,span=span) i <-i+1 } results in: 1 2 3

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread tshort
Another option for creating XLS files it to write out HTML instead. Excel can read html files just fine, and a useful trick is giving the html file a .xls extension. So, from the user's point of view, it is an excel file even though it's just an html file. Using html works great for embedding li

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Kasper Daniel Hansen
The gdata etc. packages (I cannot remember which of the g* packages it is) contains a read.xls function which reads an excel file based on a PERL script. I have used it for small stuff and for that it worked fine. I don't think they contain a write module though. Kasper On Feb 8, 2007, at

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Gabor Grothendieck
I meant that the machine has Excel on it. Excel does not have to be running prior to running the R code as the R code will start up and shut down Excel itself. On 2/8/07, Gabor Grothendieck <[EMAIL PROTECTED]> wrote: > Its not entirely clear to me what it is that you are looking > for. Maybe you

Re: [Rd] RPM support for package installation?

2007-02-08 Thread Jeffrey J. Hallman
I feel your pain. At my workplace, the network administrators insist that anything that is to be distributed across the network be packaged up in an RPM. I have my own library of packages accessible to my section members, but when I want to make something available to everyone, I have to create a

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Gabor Grothendieck
Its not entirely clear to me what it is that you are looking for. Maybe you want to create an Excel spreadsheet with a hyperlink to a web page? This R code will do that. It requires a Windows machine that has Excel running on it. library(RDCOMClient) xl <- COMCreate("Excel.Application") xl[["V

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Mark W Kimpel
Thanks for the useful suggestions. I am not as CS savvy as some of you, so maybe Hans-Peter could reply? I haven't checked into it, but does his package write to files that are OpenOffice compliant? Would that satisfy more users? Mark Hin-Tak Leung wrote: > James W. MacDonald wrote: >> Have

[Rd] strategies for incorporating a data= argument

2007-02-08 Thread Ben Bolker
As I've mentioned here, before, I'm working on an extended version of mle(), a function from the stats4 package that's a wrapper for optim(). I'd like (against the advice of Peter Dalgaard -- sorry) to incorporate a "data" argument, similar to the arguments in lm, nls, nlme, etc., that would

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Armstrong, Whit
you can also use my package which uses Jakarta POI to write the excel files. It can be used on any platform that supports java. The Perl solution may be better if you want to do anything complicated, but this package supports writing all basic R objects. http://code.google.com/p/rexcelpoi/ >

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Hin-Tak Leung
James W. MacDonald wrote: > Have you looked at RDCOMClient? I would imagine you could do what you > want with this package. > > http://www.omegahat.org/RDCOMClient/ Interesting point. But the dcom client would be windows-specific? (those I mentioned - the perl mondules, openoffice, run on window

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread James W. MacDonald
Have you looked at RDCOMClient? I would imagine you could do what you want with this package. http://www.omegahat.org/RDCOMClient/ Best, Jim Hin-Tak Leung wrote: > I don't know of any native xls read/write facility in R, either > in core or as add-ons (I could be wrong), but if you want some s

Re: [Rd] xlsReadWrite Pro and embedding objects and files in Excel worksheets

2007-02-08 Thread Hin-Tak Leung
I don't know of any native xls read/write facility in R, either in core or as add-ons (I could be wrong), but if you want some source code to scavenge on to build some R package out of it, there are two perl modules, Spreadsheet::ParseExcel and Spreadsheet::WriteExcel which are small enough to "re

Re: [Rd] possible bug: dev.copy / could not find any X11 fonts

2007-02-08 Thread R. Villegas
2007/1/31, Tamas K Papp <[EMAIL PROTECTED]>: > Hi, > > I am experiencing something strange, and thought I would ask before > reporting a bug. I trimmed it down to a self-contained example, > attached as an R file. The purpose of the functions is to save the > plots into a ps file and simultaneous