Consider the case of a response vs time for multiple measurements on
subjects. If one has both fixed and random effect for slope and
intercept, it means there is a separate linear relationship with time for
each subject (the random effect) and that the population average may have
a non-zero
Is there some clever way of pasting results from R into Excel or Word, as
tab limited format so they are easy to turn into a formatted table.
Or is there some other way of doing this to avoid the time spent
reformatting the output for presentation.
If different, I am also interested in an
[EMAIL PROTECTED] (Graham M Smith) writes:
Is there some clever way of pasting results from R into Excel or Word, as
tab limited format so they are easy to turn into a formatted table.
Have a look at write.table().
--
O__ Peter Dalgaard Blegdamsvej 3
c/ /'_ ---
Graham M Smith wrote:
Is there some clever way of pasting results from R into Excel or Word, as
tab limited format so they are easy to turn into a formatted table.
Or is there some other way of doing this to avoid the time spent
reformatting the output for presentation.
To copy/paste your
Anders,
This seems a good start, and I will try it get it to work, on of the
issues is that the results output is more complex than simply split by
comma eg a typical Summary output of my current data set (below)
However, I am a lot further forward than I was a few hours ago.
Thanks
Uwe,
To copy/paste your data.frame X to Excel, use the following lines to
write it to the clipboard from R:
Thanks, this is certainly a step in the right direction, it doesn't work
as it stands but it has given me a start
If different, I am also interested in an answer to the same
Graham M Smith graham.smith at myotis.co.uk writes:
: Is there some clever way of pasting results from R into Excel or Word, as
: tab limited format so they are easy to turn into a formatted table.
Try this:
data(iris) # get a test data frame
require(R2HTML)
HTML( iris,
Hello,
Im using the function l1ce (L1-constrained estimation) from the lasso2
package.
when I try the example from the help pages
data(Prostate)
l1c.P - l1ce(lpsa ~ ., Prostate, bound=.5)
coef(l1c.P)
(Intercept) lcavol lweight age lbph
svi
0.7284810757
I am trying to plot time variable (the time is recoded for three days at 5 minutes
interval in the format of 2001-05-14 13:45:00) VS. blood pressure. My code is the
following:
plot(time, bloodpressure,xlab=Time,ylab=bPress,main=Time VS Blood Pressure,
type=l, xaxt=n)
r -
I tried bootstrap on a sample of 13,000 observations:
It works fine when R = 200:
boot(data, cor.i, R = 200)
However, when R = 400, I got:
boot(data, cor.i, R = 400)
Killed
Any suggestions/ideas?
Thank you very much
Xiao
__
[EMAIL PROTECTED]
Gabor,
: Is there some clever way of pasting results from R into Excel or
Try this:
data(iris) # get a test data frame
require(R2HTML)
HTML( iris, file(clipboard,w), append=F )
This worked exactly as I was hoping.
Many thanks,
Graham
On Sun, 11 Apr 2004, Linda portman wrote:
I am trying to plot time variable (the time is recoded for three days at 5 minutes
interval in the format of 2001-05-14 13:45:00) VS. blood pressure. My code is the
following:
plot(time, bloodpressure,xlab=Time,ylab=bPress,main=Time VS Blood
On Sun, 11 Apr 2004, XIAO LIU wrote:
I tried bootstrap on a sample of 13,000 observations:
It works fine when R = 200:
boot(data, cor.i, R = 200)
However, when R = 400, I got:
boot(data, cor.i, R = 400)
Killed
Any suggestions/ideas?
Read the posting guide and tell us at least what
I'm trying to do some smoothing with lme and am having some difficulty
bringing commands over from S-PLUS to R. I have the following setup
(modified from Ngo and Wand, 2004):
set.seed(1)
x - runif(200)
y - sin(3*pi*x) + rnorm(200)*.4
## library(splines)
z - ns(x, 4)
The following runs without
I have a variable named Medicine which has seven values in date format, on the
following plot, how can I use a red line to indicate the time when the medicine was
taken on x axis?
The following is my original plot of blood pressure vs. time.
plot(time,
Roger D. Peng [EMAIL PROTECTED] writes:
f - lme(y ~ 1, random = pdIdent(~ -1 + z))
But in R I get
library(nlme)
f - lme(y ~ 1, random = pdIdent(~ -1 + z))
Error in getGroups.data.frame(dataMix, groups) :
Invalid formula for groups
Does the S-PLUS lme have some default
What happens when I pass an array to a dynamically linked C routine?
Is only its reference copied when an array is passed and returned?
Or, is its whole content copied?
In R extension manual, I found the following description.
But, I can't know exactly which is true.
There can be up to 65
I thought that description is rather clear. If `x' is a vector of doubles,
then
result - .C(myCfunc, x = x)
makes a copy of `x' to be passed to `myfunc'. The copy in R is not touched.
When `myfunc' returns, another copy is made and placed into result[[x]].
There's the `DUP' argument in
Thanks, Andy.
Let me ask a little more about the DUP argument.
In the manual, I can see that only reference copy happens when passing an
array,
if DUP=FALSE. Then, what happens when returning it in a list, if DUP=FALSE?
Another reference copy, or deep copy?
I am trying to implement a dynamic
My understanding is that if DUP=FALSE, no copying is done in either
direction.
If you want to avoid copying, the .Call interface is probably more suitable,
as you pass the actual R objects to the C function. I'm not familiar with
that, though.
Andy
From: Shin, Daehyok [mailto:[EMAIL
On Sun, 11 Apr 2004 21:25:13 -0400, you wrote:
My understanding is that if DUP=FALSE, no copying is done in either
direction.
If you want to avoid copying, the .Call interface is probably more suitable,
as you pass the actual R objects to the C function. I'm not familiar with
that, though.
If
For me it's just a matter of getting my hands dirty, I guess. For whatever
reason I seem to have a mental block about the PROTECT/UNPROTECT business...
Best,
Andy
From: Duncan Murdoch [mailto:[EMAIL PROTECTED]
On Sun, 11 Apr 2004 21:25:13 -0400, you wrote:
My understanding is that if
Thanks, Murdoch.
The .Call is what I want.
In R extension manual,
Neither .Call nor.External copy their arguments. You should treat arguments
you receive through these
interfaces as read-only.
Daehyok Shin
-Original Message-
From: Duncan Murdoch [mailto:[EMAIL PROTECTED]
Sent:
On Sun, 11 Apr 2004 21:43:58 -0400, you wrote:
For me it's just a matter of getting my hands dirty, I guess. For whatever
reason I seem to have a mental block about the PROTECT/UNPROTECT business...
Just protect every SEXP until you don't care if it goes away. It
might be possible to skip some
Hello,
I am using R to look at whole-genome gene expression data. This means
about 27,000 genes, each with a vector of numbers reflecting expression at
different tissues and times. I need to do an all against all co-expression
calculation (basically, just calculate Pearson's r for every
On Sun, 11 Apr 2004 19:15:08 -0700 (PDT), you wrote:
Hello,
I am using R to look at whole-genome gene expression data. This means
about 27,000 genes, each with a vector of numbers reflecting expression at
different tissues and times.
How long is that vector? Presumably shorter than 27000.
I
Hi everyone,
I'm analysing a survival analysis data set at the moment with missing
values in the covariate and survival vectors (I have about 60
variables). I know there are some functions on the CRAN network to
deal with missing values in general multivariate data. Does anybody
know of
In R, I see support for ARCH models and for ARMA models (in the
tseries package). How would we estimate the workhorse model where
stock returns are ARMA with ARCH errors?
I am aware of the paper by Andy Weiss. I have used this model quite a
bit using stata and consider it a staple. I couldn't
Hi,
- Original Message -
From: Ajay Shah [EMAIL PROTECTED]
But this doesn't work since if D is a data frame, you can't say
D[d]. Let me show you:
x = runif(100)
y = runif(100)
D = data.frame(x, y)
d = c(7,3,2)
E = D[d]
Error in [.data.frame(D, d) : undefined columns
sdratio - function(D, d) with( D[d,], sd(x)/sd(y) )
Ajay Shah ajayshah at mayin.org writes:
:
: I know that if:
:x = seq(1,10)
:d = c(7,3,2)
: and if I say
:y = x[d]
: then I get the vector y as (7,3,2). Very clever! This idea is used
: intensively with the boot library.
:
: Now
plot(1:10)
abline(v=c(3,5,7), col=red)
Linda portman lindaportman at yahoo.com writes:
:
: I have a variable named Medicine which has seven values in date format, on
the following plot, how can I use
: a red line to indicate the time when the medicine was taken on x axis?
:
: The following
31 matches
Mail list logo