Hi Harsh,
If your project is so specific on the regression model, my suggestion
is to use tcl/tk or Gtk2 interface instead of FLEX, because your
requirement on interaction is simple (e.g. you don't need to
drag-and-drop points).
I think the example 'run.cor2.examp()' in 'TeachingDemos' package ca
Dear Sir/Madam,
I converted my Stata Rgenmetvl.dta file with read.dta succesfully in R's
Rgenmetvl.Rdata. However, factors give problem in certain calculations,
e.g.:
> mean(Rgenmetvl$sex)
[1] NA
Warning message:
In mean.default(Rgenmetvl$sex) :
argument is not numeric or logical: returning NA
W
Hi,
I am trying to find marginal pdfs when joint pdf of two continuous variables is
given.
Simple case is like this:
The joint pdf is
f(x,y) = 4xy, x lies between 0 and 1, and y also lies between 0 and 1.
I tried following crude way of doing it but it is not complete.
Could you post a sugge
Rob Bakker wrote:
Dear Sir/Madam,
I converted my Stata Rgenmetvl.dta file with read.dta succesfully in R's
Rgenmetvl.Rdata. However, factors give problem in certain calculations,
e.g.:
mean(Rgenmetvl$sex)
[1] NA
Warning message:
In mean.default(Rgenmetvl$sex) :
argument is not numeric or logi
I am trying to debug a loop. Is there a way to print the value of a variable
that is inside a loop? I have a vector v and inside a loop I have v[i] where
i is the index of the loop. Is there a way to see v[i] per loop so that I
can see what is going on?
Thanks
--
View this message in context:
ht
Hi,
I am new to R. Can anyone tell me how to evaluate an expression stored
in a string?
such as:
> expr <- "3*5"
I want to get the result 15.
Thanks in advance.
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do
Hi, Ning,
Try: eval(parse(text = expr))
HTH,
--sundar
On Sat, May 2, 2009 at 5:39 AM, Ning Ma wrote:
> Hi,
>
> I am new to R. Can anyone tell me how to evaluate an expression stored
> in a string?
> such as:
>> expr <- "3*5"
> I want to get the result 15.
>
> Thanks in advance.
>
> ___
> eval(parse(text=expr))
[1] 15
2009/5/2 Ning Ma :
> Hi,
>
> I am new to R. Can anyone tell me how to evaluate an expression stored
> in a string?
> such as:
>> expr <- "3*5"
> I want to get the result 15.
>
> Thanks in advance.
>
> __
> R-help@r-projec
Thank you and Sunder!
On Sat, May 2, 2009 at 8:49 PM, ronggui wrote:
>> eval(parse(text=expr))
> [1] 15
>
>
> 2009/5/2 Ning Ma :
>> Hi,
>>
>> I am new to R. Can anyone tell me how to evaluate an expression stored
>> in a string?
>> such as:
>>> expr <- "3*5"
>> I want to get the result 15.
>>
>>
On May 2, 2009, at 7:59 AM, onyourmark wrote:
I am trying to debug a loop. Is there a way to print the value of a
variable
that is inside a loop? I have a vector v and inside a loop I have
v[i] where
i is the index of the loop. Is there a way to see v[i] per loop so
that I
can see what
See ?cat, e.g.
> v <- seq(10, 50, 10)
> for(i in seq_along(v)) cat("v[", i, "] =", v[i], "\n")
v[ 1 ] = 10
v[ 2 ] = 20
v[ 3 ] = 30
v[ 4 ] = 40
v[ 5 ] = 50
On Sat, May 2, 2009 at 7:59 AM, onyourmark wrote:
>
> I am trying to debug a loop. Is there a way to print the value of a variable
> that is
I just upgraded my version of R from 2.8.1 to 2.9.0. After doing so, I now
have problems using the package installer to reinstall all my packages.
Some download and install without problems, but for others, I get the
spinning pinwheel and after even 10 minutes, nothing is downloaded. R stops
re
Santosh wrote:
Dear R-sians...
Installing libraries
Well, I think you want to install a *package* into a library.
through RCMD INSTALL does not seem to work.. Is the
following command c
R CMD install -l "C:\Program Files\R\R-2.8.1\library"
Please use forward slashes or soubled backslash
cls59 wrote:
RON70 wrote:
Dear all, is it possible to extract the seed that was used for some random
number generation? For example suppose I draw a random sample of size 1000
from a normal population :
rnorm(1000)
Now I want to know what seed R used for that sample generation. Any way
out?
Dear R Users,
I have a data frame of the nature:
> head(aggregate_1986)
Latitude Mean Annual Simulated Runoff per 1° Latitudinal Band
1 -55574.09287
2 -54247.23078
3 -53
onyourmark wrote:
Error in matrix(unlist(value, recursive = FALSE, use.names = FALSE), nrow =
nr, :
invalid 'ncol' value (too large or NA)
the statement was:
for (i in v) {for (j in m[0,]){if(v[i]==m[0,j]){M[,-j]}}}
That code does not make sense at all:
- What is m[0,] ? Note that R
Steve Murray wrote
>
>I have a data frame of the nature:
>I am hoping to plot columns 2 and 3 against Latitude. I understand that you
>have to do this by plotting one column at a time, so I have been starting by
>attempting the following, but receiving errors:
>
>
>I'm obviously doing someth
you might also look at matplot
d=data.frame(x=1:10,y1=sort(rnorm(10)),y2=sort(rnorm(10)))
matplot(d[,1],d[,2:3],type='l',lty=1:2)
David Freedman
Steve Murray-3 wrote:
>
>
> Dear R Users,
>
> I have a data frame of the nature:
>
>> head(aggregate_1986)
> Latitude Mean Annual Simulated R
Renee,
I finally found the problem. You misspecified fun.at as a list with two
elements. It needed 6 elements to correspond with fun:
fun.at=list(at.surv, at.surv, at.surv,
at.med, at.med, at.med)
You have subjects with a very good prognosis and you are asking for
median surviva
David,
You're right. I've to post the attachments on the web. Do you have a
suggestion where I may put them?
Thanks.
Fritsander
-Original Message-
From: David Winsemius [mailto:dwinsem...@comcast.net]
Sent: zaterdag 2 mei 2009 1:45
To: Fritsander Lahr
Cc: r-help@r-project.org
Subject:
I have: f <- ols( y1 ~ (rcs(x1,3) + rcs(x2,3) + rcs(x1,3) %ia% rcs(x2,3) ) )
Then I do: plot(f)
This plots y1 against x2 for a given value of x1.
Is there a way to make it *also* plot y1 against x1 for a given value of x2?
If not, I guess I can do coplot(y1 ~ x1 | x2).
Thanks in advance,
sp
Hi David,
I think the revolution blog is fantastic and a great service to the R
community. Thanks for all your hard work!
Hadley
On Fri, May 1, 2009 at 4:54 PM, David M Smith
wrote:
> I write about R every weekday at http://blog.revolution-computing.com
> . In case you missed them, here are so
Hello,
I'm using R-2.9 and have a question about integer ranges. On C, (OS X
platform),
LONG_MIN and LONG_MAX(from limits.h) correspond to -2147483648(-2^31)
and 2147483647 (2^31-1)
In Java(1.4), Integer.MIN_VALUE and Integer.MAX_VALUE have the same values.
On R, as.integer(2^31-1) is the maximum
You've hit on the reason -- representation of NA
src/main/arithmetic.c:157:R_NaInt = INT_MIN;
(R-devel seems more appropriate for this question).
Martin
Saptarshi Guha writes:
> Hello,
> I'm using R-2.9 and have a question about integer ranges. On C, (OS X
> platform),
> LONG_MIN and LON
> You've hit on the reason -- representation of NA
>
> src/main/arithmetic.c:157: R_NaInt = INT_MIN;
Aha! Yes, I missed that.
>
> (R-devel seems more appropriate for this question).
Yes, i was not sure.
Thank you
Saptarshi
__
R-help@r-project.org
Greetings:
This should be easy but it isn't.
I have a home-brew package that works fine, with compiled html help pages,
all 150 of them. I want to make a similar package but not from scratch
since only a half-dozen routines are changed. So I created a new directory,
copied the old package
Oops! I forgot the obligatory OS and session info:
> sessionInfo()
R version 2.8.1 (2008-12-22)
i386-pc-mingw32
locale:
LC_COLLATE=English_United States.1252;LC_CTYPE=English_United
States.1252;LC_MONETARY=English_United
States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252
How would I set the "scales" property of a lattice levelplot, so that
I can add specific annotations at specific positions?
For example, I have a 200 x 1000 element levelplot. Along the y-axis
(along the 1000-element axis) I would like to add annotations on the
left side of the levelplot at
On 02/05/2009 6:37 PM, Charles Annis, P.E. wrote:
Greetings:
This should be easy but it isn't.
I have a home-brew package that works fine, with compiled html help pages,
all 150 of them. I want to make a similar package but not from scratch
since only a half-dozen routines are changed.
On May 2, 2009, at 4:09 PM, x wrote:
I have: f <- ols( y1 ~ (rcs(x1,3) + rcs(x2,3) + rcs(x1,3) %ia%
rcs(x2,3) ) )
Then I do: plot(f)
This plots y1 against x2 for a given value of x1.
Is there a way to make it *also* plot y1 against x1 for a given
value of x2?
Are you using the Design
On May 2, 2009, at 7:00 PM, Alex Reynolds wrote:
How would I set the "scales" property of a lattice levelplot, so
that I can add specific annotations at specific positions?
For example, I have a 200 x 1000 element levelplot. Along the y-axis
(along the 1000-element axis) I would like to ad
Well there are always the print and cat functions which print to standard
output. You may also want to look at flush.console if buffering is a problem.
Also using "\b" or "\r" with cat can keep from producing too much output.
There are also the progress bar functions (winProgressBar, tkProgre
You have use a zero index. This is not allowed in R (normally).
Also your code, even if corrected, would do nothing so I suspect your problems
do not stop there.
Did you really mean "for(i in v) if(v[i] ... "? Very subtle if you did.
Bill Venables
http://www.cmis.csiro.au/bill.venabl
print(c(i, v[i]))
Bill Venables
http://www.cmis.csiro.au/bill.venables/
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On
Behalf Of onyourmark
Sent: Saturday, 2 May 2009 9:59 PM
To: r-help@r-project.org
Subject: [R] print value of variable
On May 2, 2009, at 5:08 PM, David Winsemius wrote:
Not sure since you have not provided a reproducible example and not
really defined what "annotations" means.
By annotations, I mean that I want to draw an object (set of poiygon()
elements that make up a genomic sequence logo), anchored at
Thank you, Duncan! You are right-as-rain: I forgot to change the aliases.
A single change from \alias{STUFF} to \alias{newSTUFF} in the
newSTUFF-package.Rd file did the trick.
Thanks!
Charles Annis, P.E.
charles.an...@statisticalengineering.com
phone: 561-352-9699
eFax: 614-455-3265
http://ww
Dear all,
I have been importing data into R from yahoo using yahooSeries, however the
older version I was using no longer works with the syntax I have developed.
I downloaded the latest package and it downloads data from the U.S. just
fine, but the ticker codes for the Australian stock exchange (
37 matches
Mail list logo