[R] Foreign function interface

2014-04-19 Thread Alex van der Spek
I read the Foreign Function Interface for R. The documentation does not prescribe the calling convention though. Does that mean __stdcall on W32 and __cdecl for Linux? Regards, Alex van der Spek __ R-help@r-project.org mailing list https

Re: [R] Automatic formula creation

2013-08-09 Thread Alex van der Spek
use trm <- Reduce(function(a,b) bquote(.(a)*.(b)), nm) formula(bquote(I(1 - Pass149) ~ .(trm) - 1)) I(1 - Pass149) ~ a * b * c * d * e * f - 1 Hope this helps, Rui Barradas Em 09-08-2013 11:40, Alex van der Spek escreveu: Say I want to compare all 5 term models from a choice of 28 d

[R] Automatic formula creation

2013-08-09 Thread Alex van der Spek
mber of terms changes. There ought to be a better way but I can't find it. Any help much appreciated! The full block of relevant code follows: Alex van der Spek + #Try all 3 band models nbands <- 5 freqs <- c('4', '

[R] cat(summary(lm(Y~x, dat = data))) cannot handle lists; dput writes too much...

2013-08-09 Thread Alex van der Spek
Is there a way to write the summary of lm objects to a text file on disk? cat won't handle the list, dput writes everything but not in human readable format. Any thoughts? Alex van der Spek __ R-help@r-project.org mailing list https://stat.et

Re: [R] list construction with automatic names

2013-07-04 Thread Alex van der Spek
>> I often find myself (wanting t)o constructing lists or >> data.frames > > Apologies; previous post should have said "Read R inforno on 'Growing > Objects'" and should have added the URL: > > http://www.burns-stat.com/pages/Tutor/R_inferno.pdf > > S Ellison > > > > ***

[R] list construction with automatic names

2013-07-04 Thread Alex van der Spek
Would there be a better way? Again, in python appending to a list is very easy but seems to be available in R only for vectors not lists? Any help much appreciated! Alex van der Spek __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listi

[R] Lattice strip with custom shingle.interval

2013-03-18 Thread Alex van der Spek
Any help much appreciated. Alex van der Spek __ 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] zoo timeseries plot; minor tic mark level control

2012-11-26 Thread Alex van der Spek
st the abbreviated name of the month (Oct and Nov). How can I add minor tic marks for the individual days? All and any help or pointers welcome. Alex van der Spek __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE d

[R] Is there an lm() equivalent of panel.lmline()?

2012-10-30 Thread Alex van der Spek
: lmcal <- lm(Xvalues ~ log(Qvalues):Tfac, data = df7) Only one value of the intercept is returned. It appears as all the 'individual' intercepts are summed to form one overall intercept. Any help much appreciated! Regards, Alex van der Spek __

[R] write.csv with append = TRUE

2012-10-10 Thread Alex van der Spek
sv(Lbys[[c]], fo, append = TRUE) : attempt to set 'append' ignored Regards, Alex van der Spek __ 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-gu

Re: [R] Summary using by() returns character arrays in a list

2012-10-10 Thread Alex van der Spek
now. Modified the summary.data.frame method to output numeric values and not the character strings. The rownames I set afterwards in a for loop. Still would like to know how to do this internal to summary.data.frame though. Regards, Alex van der Spek > Hi > >> -Original Message-

[R] Summary using by() returns character arrays in a list

2012-10-10 Thread Alex van der Spek
ric matrices with as rownames the summary statistic's name ("Min.", "Max." etc) and as values the numeric values of the calculated summary statistic. Any help much appreciated! Regards, Alex van der Spek > str(Lbys) List of 2 $: 'table' chr [1:6, 1:19] &

Re: [R] Calling function in DLL using .C

2012-01-24 Thread Alex van der Spek
Sorry, this works www.zdoor.home.xs4all.nl Thank you, Alex van der Spek On 01/24/2012 07:21 PM, Duncan Murdoch wrote: On 24/01/2012 11:55 AM, Alex van der Spek wrote: Uploaded the DLL here: http://www.filefactory.com/file/c2c56ad/n/Planck.dll I get: 403 Forbidden Request forbidden by

Re: [R] Calling function in DLL using .C

2012-01-24 Thread Alex van der Spek
names. Reading up on gcc in the mean time. Thank you, Alex van der Spek > On 24/01/2012 10:35 AM, Alex van der Spek wrote: >> Yes, sorry, I am learning how to do this. I am a simple and ageing >> physicist who grew up with Fortran and Algol. >> >> Just wondering if

[R] Calling function in DLL using .C

2012-01-24 Thread Alex van der Spek
fo returns the name and a pointer to the address of the function planckwR. The $package element of the list returned by getNativeSymbolInfo is NULL, which adds to my confusion as it should be a list of 3 elements. What am I missing here? All help much appreciated. Alex van der Spek ___

Re: [R] Calling Windows DLL using .C; function name not known but in exports.

2012-01-22 Thread Alex van der Spek
27;planckwR',...) not recognize it? Alex van der Spek On 01/22/2012 02:40 AM, Duncan Murdoch wrote: On 12-01-20 10:05 AM, Alex van der Spek wrote: First time ever that I try to call subroutines in a Win DLL using R. Have done this before using VBA and Python. The C code's function argume

[R] Calling Windows DLL using .C; function name not known but in exports.

2012-01-20 Thread Alex van der Spek
e exports table using dumpbin. I use Visual C++ 97 compiler. Old but works. It does change the FPU control word, which I know it should not. Working on that one too. Any tips? Any help much appreciated. Alex van der Spek __ R-help@r-project.org mailing list

[R] matplot with dates/times on horizontal axis

2011-07-12 Thread Alex van der Spek
for instance format="%H:%M". Passing a vector of formatted strings does not work. Any obvious other ways fail upon me as well. Any ideas to make this work? Thanks in advance, Alex van der Spek __ R-help@r-project.org mailing list https://stat.e

[R] plot.ts versus plot.zoo

2010-09-22 Thread Alex van der Spek
side=2) } } This leads to a blank window. I am stuck with the intricacies of the plotting and axis generation here. Thank you in advance, Alex van der Spek __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do re

[R] Decoding raw vectors every other byte

2010-06-16 Thread Alex van der Spek
e a function with a for loop and vectorize that function but is there perhaps an easier way to write this? It is enough if this works on windows only. No need to worry about endianness. Thanks in advance. Alex van der Spek __ R-help@r-project.org m

[R] Interaction versus combinations

2010-06-03 Thread Alex van der Spek
ot;3.9" "6.9" I have been unable to find how to get the combinations. Of course with some string manipulations this can be done for this toy example. There should be something in R to make this easy? Thanks in advance Alex van der Spek __ 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] Building a what list for scan to use

2010-05-31 Thread Alex van der Spek
=0) All are numeric, either decimal or hexadecimal. Thanks in advance, Alex van der Spek __ 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 a

Re: [R] Memory issue

2010-05-05 Thread Alex van der Spek
, unfortunately it is not upon me to choose the system. Alex van der Spek __ 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

[R] Memory issue

2010-05-05 Thread Alex van der Spek
. Regards, Alex van der Spek __ 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] Lattice in a loop does not produce output

2009-08-18 Thread Alex van der Spek
I cannot understand why xyplot does not work within a simple for loop. This works up to the for loop; inside the for loop the png files are opened and closed, but nothing is plotted. No error messages are written to the console either. This is the case on both Windows and Linux. By the way, runn

[R] Lattice: How to do error bars

2009-08-11 Thread Alex van der Spek
xcellent. Most of the time I can save myself. Thanks in advance! Alex van der Spek __ 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 c

Re: [R] Lattice: change background of conditioning variable box

2009-08-05 Thread Alex van der Spek
Yes it does! Thank you Erik! I had not thought about searching under 'trellis'! Alex van der Spek On Wed, 2009-08-05 at 09:53 -0500, Erik Iverson wrote: > Alex, > > Does changing the color argument of the default theme associated with the > device to what you wan

[R] Lattice: change background of conditioning variable box

2009-08-05 Thread Alex van der Spek
ut to no avail. Is there anyone who can point me in the right direction? Thanks in advance! Alex van der Spek __ 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

[R] Constrained fits: y~a+b*x-c*x^2, with a,b,c >=0

2009-05-27 Thread Alex van der Spek
(or zero) values of x. The help pages for lm do not contain any info on constrained fitting. Does anyone know how to? Regards, Alex van der Spek __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting gu