hi,
I m said to display graph in browser using Rook.
So i found a code i.e
library(Rook) # for web functionality
library(ggplot2) # for graphing
library(tseries) # used to grab time series from yahoo for stock symbols
library(plyr) # data tweaks
PIC.DIR = paste(getwd(), 'pic', sep='/')
Dear Rui Barrada,
Thank you so much for your kind sharing. It's really help.
Regards,
Lim Hock Ann
From: Rui Barradas
Cc: R-Help
Sent: Tuesday, September 18, 2012 12:03 AM
Subject: Re: [R] Problem with Stationary Bootstrap
Hello,
The problem is your
On Sep 17, 2012, at 8:23 PM, Jingwan Li wrote:
> Hi all,
>
> Can anyone tell me how to convert a R script to a standalone executable
> that can be installed and run on any Windows machines?
> Thanks in advance.
R is an interpreted language. There is no compiler that creates standalone
modules
ok, I see now!
here it is the reproducible example along with the final code (aslo with
the median line instead of a point)
thank you all for the great help
max
# start code
library(lattice)
test<-structure(list(site = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 2L,
2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
I am running Rmpi and MPICH2 to do parallelization in a Windows 7 machine.
I am only using my PC's cores. Parallelization for standard R code works
fine. For S4 code I am having the following problem:
Let us say I have a class A and a subclasses B and C (both B and C
"contains" A). I declared a me
Hello all,
I'm new in R, and I have a data-frame like this (dput information below):
Specie Fooditem Occurrence Volume
1 Schizodonvegetal 1 0.05
2 Schizodon sediment 1 0.60
3 Schizodonvegetal 1 0.15
4 Schizodon
On Sep 17, 2012, at 7:28 PM, arun wrote:
> HI,
> Try this:
> mydata$Gain<-rep(tapply(mydata$Mass,mydata$Sample,FUN=function(x)
> (x[3]-x[2])),each=length(unique(mydata$Sample)))
> mydata
> # Sample Time Mass Gain
> #1 11 3.0 0.3
> #2 12 3.1 0.3
> #3 13 3.4 0.3
Hi all,
Can anyone tell me how to convert a R script to a standalone executable
that can be installed and run on any Windows machines?
Thanks in advance.
Jingwan
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
https:/
HI,
Modified version of my earlier solution:
res1<-tapply(mydata$Mass,mydata$Sample,FUN=function(x) (x[3]-x[2]))
res2<-data.frame(Sample=names(res1),Gain2_3=res1)
merge(mydata,res2)
#Sample Time Mass Gain2_3
#1 1 1 3.0 0.3
#2 1 2 3.1 0.3
#3 1 3 3.4 0.3
#4
HI,
Try this:
mydata$Gain<-rep(tapply(mydata$Mass,mydata$Sample,FUN=function(x)
(x[3]-x[2])),each=length(unique(mydata$Sample)))
mydata
# Sample Time Mass Gain
#1 1 1 3.0 0.3
#2 1 2 3.1 0.3
#3 1 3 3.4 0.3
#4 2 1 4.0 0.1
#5 2 2 4.3 0.1
#6 2
Hi all,
I 'm doing the exercise given in the 'SDM with R' (Robert J. Hijmans and Jane
Elith), chapter 4.2, regarding extracting values . I tried to do the same using
my own data as well. Each cases i received the following error message ;
"Error in .xyValues(x, as.matrix(y), ...) : xy should ha
On Sep 17, 2012, at 6:27 PM, s.s.m. fauzi wrote:
> I have big .csv file. I would like to filter that file into a new table.
>
>
> For example, I have .csv file as below:
>
>
>
>
> f1 f2 f3 f4 f5 f6 f7 f9 f10 f11
>t1 1 0 1 0 1 0 0 0 01
>t2 1 0 0 0 0
I have big .csv file. I would like to filter that file into a new table.
For example, I have .csv file as below:
f1 f2 f3 f4 f5 f6 f7 f9 f10 f11
t1 1 0 1 0 1 0 0 0 01
t2 1 0 0 0 0 1 1 1 11
t3 0 0 0 0 0 0 0 0 00
t4 1
Problem solved by Josh O'Brien on stackoverflow,
http://stackoverflow.com/questions/12393004/parsing-back-to-messy-api-strcuture/12435389#12435389
some_magic <- function(df) {
## Replace NA with "", converting column types as needed
df[] <- lapply(df, function(X) {
if(any(i
Or diff(x[2:3])
Rui Barradas
Em 18-09-2012 01:05, David Winsemius escreveu:
On Sep 17, 2012, at 5:00 PM, David Winsemius wrote:
On Sep 17, 2012, at 4:15 PM, Julie Lee-Yaw wrote:
Hi
I have a dataframe similar to:
Sample<-c(1,1,1,2,2,2,3,3,3)
Time<-c(1,2,3,1,2,3,1,2,3)
Mass<-c(3,3.1,3.4,4,4
On Sep 17, 2012, at 5:00 PM, David Winsemius wrote:
>
> On Sep 17, 2012, at 4:15 PM, Julie Lee-Yaw wrote:
>
>> Hi
>>
>> I have a dataframe similar to:
>>
>>> Sample<-c(1,1,1,2,2,2,3,3,3)
>>
>>> Time<-c(1,2,3,1,2,3,1,2,3)
>>
>>> Mass<-c(3,3.1,3.4,4,4.3,4.4,3,3.2,3.5)
>>
>>> mydata<-as.data
On Sep 17, 2012, at 4:15 PM, Julie Lee-Yaw wrote:
> Hi
>
> I have a dataframe similar to:
>
>> Sample<-c(1,1,1,2,2,2,3,3,3)
>
>> Time<-c(1,2,3,1,2,3,1,2,3)
>
>> Mass<-c(3,3.1,3.4,4,4.3,4.4,3,3.2,3.5)
>
>> mydata<-as.data.frame(cbind(Sample,Time,Mass))
>
Please tell me where you learned tha
Hello,
Try the following.
sp <- split(mydata, mydata$Sample)
do.call(rbind, lapply(sp, function(x){x$Gain <- x$Mass[3] - x$Mass[2]; x}))
Hope this helps,
Rui Barradas
Em 18-09-2012 00:15, Julie Lee-Yaw escreveu:
> Hi
>
> I have a dataframe similar to:
>
>> Sample<-c(1,1,1,2,2,2,3,3,3)
>> Time<-
Julie -
Since the apply functions operate on one row at a time, they
can't do what you want. I think the easiest way to solve your
problem is to reshape the data set, and merge it back with the
original:
dd = data.frame(Sample=c(1,1,1,2,2,2,3,3,3),
+ Time=c(1,2,3,1,2,3,1,
On 12-09-17 6:26 PM, Søren Højsgaard wrote:
Dear list,
Given a linear mixed model (from lme4) I want to 1) first change the input
dataset and then 2) change the model formula. I want this to happen in a
function call;
Please see below. Options 1) and 2) below work whereas 3) fails with the mess
Hi
I have a dataframe similar to:
>Sample<-c(1,1,1,2,2,2,3,3,3)
>Time<-c(1,2,3,1,2,3,1,2,3)
>Mass<-c(3,3.1,3.4,4,4.3,4.4,3,3.2,3.5)
>mydata<-as.data.frame(cbind(Sample,Time,Mass))
Sample Time Mass
1 1 1 3.0
2 1 2 3.1
3 1 3 3.4
4 2 1 4.0
5 2 2 4
On Sep 17, 2012, at 3:26 PM, Søren Højsgaard wrote:
> Dear list,
> Given a linear mixed model (from lme4) I want to 1) first change the input
> dataset and then 2) change the model formula. I want this to happen in a
> function call;
> Please see below. Options 1) and 2) below work whereas 3)
Dear list,
Given a linear mixed model (from lme4) I want to 1) first change the input
dataset and then 2) change the model formula. I want this to happen in a
function call;
Please see below. Options 1) and 2) below work whereas 3) fails with the
message
> foo()
Error in is.data.frame(data) :
On 17 September 2012 at 23:51, Conklin, Mike (GfK Custom Research NA) wrote:
| I am sure I am providing insufficient information, please ask for more.
|
| I installed R 2.14.2 on my Ubuntu laptop with and AMD64 processor and also
installed RStudio and everything worked fine.
|
| Now, I tried t
I am sure I am providing insufficient information, please ask for more.
I installed R 2.14.2 on my Ubuntu laptop with and AMD64 processor and also
installed RStudio and everything worked fine.
Now, I tried to build R 2.15.1 from source and installed it using defaults.
RStudio now complained th
Google est ton ami:
http://lmgtfy.com/?q=R+statistiques+fran%C3%A7ais
Le deuxième parait prometteur.
Bonne chance,
Rui Barradas
Em 17-09-2012 20:06, Seydou Badiane escreveu:
HELLO, I SHALL NEED A HELP. It is my official language(tongue) is French,
even if I manage little in English, I shall li
On Mon, Sep 17, 2012 at 6:27 PM, Christof Kluß wrote:
> Hi
>
> I would like to have something like
>
> str <- "df$JT == 12"
>
> fun <- function(df) {
>
> b <- eval(parse(str))
>
> return(b)
> }
>
> but for performance "eval(parse(a))" should not be evaluated at each
> function call, but should
On Tue, Sep 18, 2012 at 7:06 AM, Jeremy Brown wrote:
> Hi,
>
> I'm trying to graph the hazard function using the survreg function with the
> distributional assumptions to be loglogistic. If
> h(t)=[lambda*alpha*(lambda*t)^(alpha-1)]/[1+(lambda*t)^alpha], what output
> from R is alpha?
survre
Thanks Yihui for normalizing my customized git URL.
The version of the package on github is in the
standard R format and that part of the README is
no longer relevant. Sorry for the confusion.
It might be simplest to pick up a tar.gz file of the source at
http://www.omegahat.org/RSXML/XML_3.94
Hello,
Maybe there are simpler ways of doing it, but try the following.
sp <- lapply(split(dat, dat$id), function(.s){
i <- min(which(.s$stat == 0), which(.s$g == 1))
.s$d <- .s$stop[i]
.s[-1][row(.s[-1]) >= i] <- NA
.s
})
dat3 <- do.call(rbind, sp)
rownames(dat3) <- seq_len(
Hi,
I'm trying to graph the hazard function using the survreg function with the
distributional assumptions to be loglogistic. If
h(t)=[lambda*alpha*(lambda*t)^(alpha-1)]/[1+(lambda*t)^alpha], what output from
R is alpha?
Thanks
[[alternative HTML version deleted]]
Hi Anthony,
You are right, read.table.ffdf does not handle additional arguments passed
on to read.table in the method read.fwf as you expect. read.table.ffdf
checks the arguments of read.fwf and colClasses is not one of them,
colClasses is part of ... which is passed on to read.table.
You should r
HELLO, I SHALL NEED A HELP. It is my official language(tongue) is French,
even if I manage little in English, I shall like understanding(including)
as fast as possible, that is why I asked if there is a page wiki in French,
thank you in advance for your answers
[[alternative HTML version d
Hi, I want to predict using airma, but I want to predict using t-2 or t-3,
instead of t-1
right now the arima() function doesn't allow me to do that, it will alwasy
return with variable t-1 ,
what is the way to skip that variable?
thanks ®ards
--
View this message in context:
http://r.789695.n
On Mon, Sep 17, 2012 at 12:51 PM, Yihui Xie wrote:
> I think the correct address for GIT should be
> git://github.com/omegahat/XML.git :) Or just
> https://github.com/omegahat/XML
>
> Regards,
> Yihui
> --
> Yihui Xie
> Phone: 515-294-2465 Web: http://yihui.name
> Department of Statistics, Iowa S
On Sep 17, 2012, at 11:32 AM, john james wrote:
> Dear R users,
>
> I have the following problems. My dataset (dat) is as follows:
>
> a <- c(1,2,3)
> id <- rep(a, c(3,2,3))
> stat <- c(1,1,0,1,0,1,1,1)
> g <- c(0,0,0,0,0,0,1,0)
> stop <- c(1,2,4,2,4,1,1.5,3)
> dat <- data.frame(id,stat,g,st
On 12-09-17 06:00 AM, r-help-requ...@r-project.org wrote:
Date: Sun, 16 Sep 2012 14:41:42 -0500
From: Dirk Eddelbuettel
To: "Eberle, Anthony"
Cc:r-help@r-project.org
Subject: Re: [R] Question about R performance on UNIX/LINUX with
different memory/swap configurations
Message-ID:<2
Dear R users,
I have the following problems. My dataset (dat) is as follows:
a <- c(1,2,3)
id <- rep(a, c(3,2,3))
stat <- c(1,1,0,1,0,1,1,1)
g <- c(0,0,0,0,0,0,1,0)
stop <- c(1,2,4,2,4,1,1.5,3)
dat <- data.frame(id,stat,g,stop)
I want to creat a new dataset (dat2) with missing values
such t
I would like to include a Mathematica notebook and cdf file (both are
ASCII files) in the \inst\doc directory as supporting documentation. These
files are not large, about 340K each one. When I check using
R CMD check --as-cran ...
I get the following warning:
..
* checking dat
Hello,
Em 17-09-2012 18:50, David Winsemius escreveu:
On Sep 17, 2012, at 4:18 AM, maxbre wrote:
here it is, I think (I hope) I'm getting a little closer with this, but
still there is something to sort out...
error using packet 1
unused argument(s) (coef =1.5, do.out=TRUE)
by reading the
On Sep 17, 2012, at 6:07 AM, Tagmarie wrote:
> Thank you Michael, that worked perfectly!
>
> Now I wonder, if it is possible to break my data further apart and put it
> together again.
> Assume I include a column for an ID in the data frame like this:
>
> dattrial2<-data.frame(a=c(1,NA,NA,NA
I think the correct address for GIT should be
git://github.com/omegahat/XML.git :) Or just
https://github.com/omegahat/XML
Regards,
Yihui
--
Yihui Xie
Phone: 515-294-2465 Web: http://yihui.name
Department of Statistics, Iowa State University
2215 Snedecor Hall, Ames, IA
On Mon, Sep 17, 2012 at
On Sep 17, 2012, at 4:18 AM, maxbre wrote:
> here it is, I think (I hope) I'm getting a little closer with this, but
> still there is something to sort out...
>
> error using packet 1
> unused argument(s) (coef =1.5, do.out=TRUE)
>
> by reading the help for panel.bwplot at the argument "stat
Hi Antony,
I don't use the function zip(). I was able to access the R documentation for
zip() (package:utils).
I am using R 2.15 in Ubuntu 12.04. If I wanted to compress files, I do
gzip() from linux terminal. I guess in windows, you can use 7-zip or other
WinZip. Is there any specifi
Thanks Michael,
I presume that the command
sudo apt-get updatewill do the trick but am emailing the appropriate group to
get more background on what packages are included in the latest ubuntu version
of R.Date: Mon, 17 Sep 2012 05:43:56 -0700
From: ml-node+s789695n4643369...@n4.nabble.com
To: h
You can use the read.dbi.ffdf and read.odbc.ffdf function in package
ETLUtils. These allow you to fetch a query directly in an ffdf. See the
examples in their corresponding documentation ?read.dbi.ffdf and
?read.odbc.ffdf or look at this blog post
http://www.bnosac.be/index.php/blog/21-readodbcffdf
HI,
May be this is what you wanted.
res1<-aggregate(dattrial2$a,list(dattrial2$Week,dattrial2$AnimalID),function(x)
sum(is.na(x)))
> split(res1,res1$Group.2)
#$Bert
# Group.1 Group.2 x
#1 3 Bert 1
#2 4 Bert 1
#$Ernie
# Group.1 Group.2 x
#3 3 Ernie 1
#4 4 Ernie
Hi,After second thought,
May be this:get(A)
[1] 1 2 3
A.K.
- Original Message -
From: Sri krishna Devarayalu Balanagu
To: "r-help@r-project.org"
Cc:
Sent: Monday, September 17, 2012 8:13 AM
Subject: [R] I want to send the vector a into the Object A...
a=c(1,2,3)
b=c(23, 24, 25)
x=
Hi James
Unfortunately, I am not certain if the "latest version"
of the XML package has the garbage collection activated for the nodes.
It is quite complicated and that feature was turned off in some versions
of the package. I suggest that you install the version of the package on github
git
Hi,
I am having trouble using constrOptim. My target is to do a portfolio
optimization and there some constraints have to be fulfilled.
1) The weight of each share of the portfolio has to be greater than 0
2) The sum of these weights has to be 1
I am able to fulfill either the first or the seco
Getting rid of one more matrix subscripting call trims the
time by another 10-20%. With the following function the times
for 10^4 reps for a a 11-row input matrix become
raw compiled
f1 5.57 3.04
f3 3.73 2.14
f5 3.45 1.95
f6 1.63 0.90
f7 1.32 0.81
f7 <- functio
Try this.
A <- get(x[1])
Jean
Sri krishna Devarayalu Balanagu wrote on
09/17/2012 07:13:51 AM:
>
> a=c(1,2,3)
> b=c(23, 24, 25)
> x=c("a", "b")
> #if (length(x[1]) == 0) {cat("x[1] is having 3 elements")}
>
> Suppose I want to send the vector a into the Object A,
> um getting only "a" as th
This is Circle 8.1.43 of 'The R Inferno'.
http://www.burns-stat.com/pages/Tutor/R_inferno.pdf
Pat
On 17/09/2012 10:47, Sri krishna Devarayalu Balanagu wrote:
Hi Everyone,
Can anyone help why the errors are coming and rectify it?
invalid.ids <- c(1,3,5)
if (length(invalid.ids)==0) {
On Sep 17, 2012, at 06:04 , Bryan Keller wrote:
> Is it possible to use "paste" to write out an expression and evaluate it?
> Suppose I want to add two vectors X1 and X2, defined as follows:
>
> X1 <- 1:6
> X2 <- 6:1
>
> If I write the following it looks like what I want but is a character:
> n
Hello,
The problem is your function calling itself until there's no more stack
memory left.
Besides, your function doesn't make any sense. You pass an argument
'fit' then do not used it but change it's value then return itself.
Corrected:
set.seed(1)
X <- runif(10, 0, 10)
Y <- 2 + 3*X
a <- data
Unlike C or C++, subscripting vector or matrix is not almost free.
Also, subscripting a matrix tends to make more time than subscripting a
vector so it can help to pull out the previous row of params once
per iteration, use vector subscripting on the that row to build the new
row, and then insert t
A<- get("a")
This will work fine
Best,
Heramb
On Mon, Sep 17, 2012 at 5:43 PM, Sri krishna Devarayalu Balanagu <
balanagudevaray...@gvkbio.com> wrote:
> a=c(1,2,3)
> b=c(23, 24, 25)
> x=c("a", "b")
> #if (length(x[1]) == 0) {cat("x[1] is having 3 elements")}
>
> Suppose I want to send the vect
Dear R experts,
I'm running the following stationary bootstrap programming to find the
parameters estimate of a linear model:
X<-runif(10,0,10)
Y<-2+3*X
a<-data.frame(X,Y)
coef<-function(fit){
fit <- lm(Y~X,data=a)
return(coef(fit))
}
result<- tsboot(a,statistic=coef(fit),R = 10,n.sim
Is there a way to set the echo to be false as the code that was presented (by
the way it worked well) shows up in the document?
Thanks for any help here.
--
View this message in context:
http://r.789695.n4.nabble.com/Sweave-problem-after-R-update-version-tp4566044p4643366.html
Sent from the
I have been having the same problem. It appears to be linked to setting the
working directory.
<<>>=
setwd("c:...")
@
Then the error arrives.
Any suggestions?
--
View this message in context:
http://r.789695.n4.nabble.com/Sweave-problem-after-R-update-version-tp4566044p4643363.html
Sent fr
Thank you Michael, that worked perfectly!
Now I wonder, if it is possible to break my data further apart and put it
together again.
Assume I include a column for an ID in the data frame like this:
dattrial2<-data.frame(a=c(1,NA,NA,NA,2,3), Week=c(3,3,3,4,4,4),
AnimalID=c("Ernie","Bert", "Ernie
here it is, I think (I hope) I'm getting a little closer with this, but
still there is something to sort out...
error using packet 1
unused argument(s) (coef =1.5, do.out=TRUE)
by reading the help for panel.bwplot at the argument "stats" it says: "the
function must accept arguments coef and d
Hi,
Try this:
dattrial<-data.frame(a=c(1,NA,rnorm(4,10)), Week=c(3,3,3,4,4,4))
aggregate(dattrial$a,list(dattrial$Week),function(x) sum(is.na(x)))
# Group.1 x
#1 3 1
#2 4 0
#or
ddply(dattrial,.(Week),summarize, sum(is.na(a)))
# Week ..1
#1 3 1
#2 4 0
#or
list1<-split(dat
a=c(1,2,3)
b=c(23, 24, 25)
x=c("a", "b")
#if (length(x[1]) == 0) {cat("x[1] is having 3 elements")}
Suppose I want to send the vector a into the Object A,
um getting only "a" as the ouput for Object A but not getting required output
as the vector with the elements 1, 2, 3 with the following code
Hi,
Try this:
expr1<-parse(text=paste(paste0("X",1:2),collapse="+"))
eval(expr1)
#[1] 7 7 7 7 7 7
A.K.
- Original Message -
From: Bryan Keller
To: r-help@r-project.org
Cc:
Sent: Monday, September 17, 2012 12:04 AM
Subject: [R] Using paste to create and evaluate a variable expression
Hello,
Now I believe I've got it. (So-so believe.)
ddply is a good idea, in my first post I was using xtabs to the same
effect, but ddply makes it a lot easier.
I had made a big mistake, though. I thought that only sequences of FALSE
were valid, hence rle(). In a follow-up post, Davide listed a
> with(dattrial, table(A_is_missing=is.na(a), Week))
Week
A_is_missing 3 4
FALSE 2 3
TRUE 1 0
> with(dattrial, table(A_is_missing=is.na(a), Week))["TRUE", ] # extract the
> missing="TRUE" row, note quotes
3 4
1 0
Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com
On Mon, Sep 17, 2012 at 2:54 PM, Jessica Streicher
wrote:
> Now i know why using else never worked for me - really, i'd consider this
> more of a bug than a feature of the language ;)
If it makes you feel any better (I can't imagine it would), javascript
has the same 'feature' for much the same
Now i know why using else never worked for me - really, i'd consider this more
of a bug than a feature of the language ;)
On 17.09.2012, at 14:35, R. Michael Weylandt wrote:
> And now it is easy to see why we should all the one true brace style ;-)
>
> Michael
>
> On Mon, Sep 17, 2012 at 12:29
Comments in-line below.
Sorry to be so long getting back to you but sleep intervened.
> -Original Message-
> From: ridav...@gmail.com
> Sent: Sun, 16 Sep 2012 21:24:15 +0200
> To: jrkrid...@inbox.com
> Subject: Re: [R] [newbie] aggregating table() results and simplifying
> code with loop
On 09/14/2012 05:00 AM, r-help-requ...@r-project.org wrote:
Hello,
Why the correlation between the random effects is negative?
library(coxme)
rats1<- coxme(Surv(time, status) ~ (1|litter), rats)
random.effects(rats1)[[1]] #one value for each of the 50 litters
print(rats1)
rats2<- lmekin(time
This is perfect, thanks!
On Mon, Sep 17, 2012 at 7:16 AM, arun wrote:
> Hi,
> Try this:
> expr1<-parse(text=paste(paste0("X",1:2),collapse="+"))
> eval(expr1)
> #[1] 7 7 7 7 7 7
> A.K.
>
>
>
>
> - Original Message -
> From: Bryan Keller
> To: r-help@r-project.org
> Cc:
> Sent: Monday,
On Sun, Sep 16, 2012 at 9:42 PM, Bazman76 wrote:
> Hi there,
>
> I used the command
>
> sudo apt-get install r-base
>
> to install R on an EC2 server as shown below:
>
> http://www.r-bloggers.com/ec2-micro-instance-of-rstudio/
>
> It works but the version of R installed is:
>
> R.version.string
>
And now it is easy to see why we should all the one true brace style ;-)
Michael
On Mon, Sep 17, 2012 at 12:29 PM, Ted Harding wrote:
> On 17-Sep-2012 09:47:41 Sri krishna Devarayalu Balanagu wrote:
>> Hi Everyone,
>> Can anyone help why the errors are coming and rectify it?
>>
>> invalid.ids <-
Bryan,
Try this.
char <- paste("X", 1:2, sep="", collapse="+")
eval(parse(text=char))
Jean
Bryan Keller wrote on 09/16/2012 11:04:19 PM:
>
> Is it possible to use "paste" to write out an expression and evaluate
it?
> Suppose I want to add two vectors X1 and X2, defined as follows:
>
> X1 <
Try downloading the zip file using the browser interface to see if it
might be something with your proxy. Do this outside of R to see if
you have the same problem. After that, you can just install from a
local zip file.
On Mon, Sep 17, 2012 at 5:21 AM, Ian Shannon
wrote:
> Hi there,
>
> I have
Most of your counting needs can be handled elegantly with the xtabs()
function (cross-tabulation). This'll work a lot faster than an iterative
method. For your data I would suggest something like this:
# Create a column indicating whether or not the value in Col2 is above 5
dataset$Col2greaterthan
I think I've sorted this out now. Debugging an R program is certainly
quite a feat but I think I'm getting there. It's worth it for the power
yielded.
On Sun, Sep 16, 2012 at 7:16 PM, Bit Rocker wrote:
> Just found a typo elsewhere in the code which looks like it's the culprit.
>
> I'm not
On 17-Sep-2012 09:47:41 Sri krishna Devarayalu Balanagu wrote:
> Hi Everyone,
> Can anyone help why the errors are coming and rectify it?
>
> invalid.ids <- c(1,3,5)
> if (length(invalid.ids)==0) {
>
> cat("No Errors f
On Mon, Sep 17, 2012 at 11:03 AM, Tagmarie wrote:
> Even though I work with R since a year or so I still struggle with simple
> problems. I hope someone can help me with this. Been trying for days and am
> a little frustrated now.
>
> I have a data frame somewhat like the one bellow:
>
> dattrial<
On 12-09-17 5:47 AM, Sri krishna Devarayalu Balanagu wrote:
Hi Everyone,
Can anyone help why the errors are coming and rectify it?
invalid.ids <- c(1,3,5)
if (length(invalid.ids)==0) {
cat("No Errors found")
Problem solved, thank you.
-Original Message-
From: Duncan Murdoch [mailto:murdoch.dun...@gmail.com]
Sent: maandag 17 september 2012 13:05
To: Franckx Laurent
Cc: 'r-help@r-project.org'
Subject: Re: [R] LoadLibrary failure: : %1 is not a valid Win32 application
although arch x64 has been
Hi Everyone,
Can anyone help why the errors are coming and rectify it?
invalid.ids <- c(1,3,5)
if (length(invalid.ids)==0) {
cat("No Errors found")
}
else
If you have a million levels is it really necessary to use a factor? I'm
not sure what advantages it will to have to a string in this circumstance
(especially since you don't seem to know the levels a priori but have to
learn them from the data).
Hadley
On Sunday, September 16, 2012, Sam Steingol
Hi there,
I have had a problem with loading the package XLConnectJars_0.2-0.zip from the
CRAN mirrors. The problem occurs when executing
utils:::menuInstallPkgs()
I have traced the problem down to the "download" internal command. It appears
that files over approx 15 MB are being truncated. The
Even though I work with R since a year or so I still struggle with simple
problems. I hope someone can help me with this. Been trying for days and am
a little frustrated now.
I have a data frame somewhat like the one bellow:
dattrial<-data.frame(a=c(1,NA,rnorm(4,10)), Week=c(3,3,3,4,4,4))
I wan
On 12-09-17 3:56 AM, Franckx Laurent wrote:
Dear all,
I have problems loading a library in the 64 version of R.
The following happens:
· I have a file, equildistC.cpp, which contains a few lines of C++ code.
· I have compiled the file using the following commands:
PATH =
c:
To dear Dr Sarkar and anyone that knows about Lattice package,
I make 4 graphs by Lattice package. Each of the graphs has two time
series. All the series are plotted in plain lines by default, and I would
like one series to be in plain line and the other to be in dotted line in
each graph. How
Dear all,
I have problems loading a library in the 64 version of R.
The following happens:
· I have a file, equildistC.cpp, which contains a few lines of C++ code.
· I have compiled the file using the following commands:
PATH =
c:\Rtools\bin;C:\Rtools\gcc-4.6.3\bin;C:\Rtools\
Hi Arun,
I tried this way, but getting an error like
Using Eclips:
âError in .rj.originals$help(..., help_type = "html") : 'topic' should be a
name, length-one character vector or reserved wordâ
Using R:
Error: could not find function "zip"
So, is it required to install any p
If you have a data frame "df" with a column "JT"
Try this one:
str <- "df$JT == 12"
fun<-function(str){b<-eval(parse(text=str))
return(b)}
fun(str)
On Mon, Sep 17, 2012 at 11:57 AM, Christof Kluß wrote:
> Hi
>
> I would like to have something like
>
> str <- "df$JT == 12"
>
> fun <- function(d
thank you for the help, bert
unfortunately, for reasons I can not understand (yet) I can not put to
wortk it all
(I'm always in trouble with the panel functions);
max
Il 14/09/2012 18:38, Bert Gunter ha scritto:
Thanks for the example. Makes it easy to see what you mean.
Yes, if I understan
On Sep 16, 2012, at 9:04 PM, Bryan Keller wrote:
> Is it possible to use "paste" to write out an expression and evaluate it?
Of course.
?as.expression
?parse
?eval
> Suppose I want to add two vectors X1 and X2, defined as follows:
>
> X1 <- 1:6
> X2 <- 6:1
>
> If I write the following it loo
On Sep 16, 2012, at 11:27 PM, Christof Kluß wrote:
> Hi
>
> I would like to have something like
>
> str <- "df$JT == 12"
>
> fun <- function(df) {
>
> b <- eval(parse(str))
>
> return(b)
> }
>
What are you trying to do?
str <- quote(df$JT == 12)
> but for performance "eval(parse(a))" s
94 matches
Mail list logo