R has a Dickey-Fuller Test implementation (adf.test) that tests for unit
roots in an autoregressive process with a constant and linear trend. Is
there a DF implementation that doesn't use the constant or trend?
Thanks,
Jake.
--
View this message in context:
http://www.nabble.com/Dickey-Fulle
Hello,
I am getting some unexpected results when using mle.stepwise:
# BEGIN
require(wle)
x1 = runif(100)
x2 = runif(100)
y = 3 + 2*x1 + rnorm(100)
# so x1 is in the model, but not x2
mle.stepwise(y ~ x1 + x2, type = "Backward")
# Backward selection gets it right, the other
Hello,
I am a beginner in R and statistics, so my question may be trivial. Sorry in
advance.
I performed a Cox proportion hazard regression with 2 categorical variables
with cph{design}. Then an anova on the results.
the output is
> anova(cph(surv(survival, censor) ~ plant + leaf.age + plant*le
Dear R users,
Does anyone know how to write a function involving derivative?
i.e. I want to implementing Newton's method in R, so my function is something
like
x<- x-y/y'
I am not sure how to write y' in my function. Can anyone help?
In addition, if I want to implementing newton's method
You might get some information about what is available in R using
the new "RSiteSearch" package. For example:
library(RSiteSearch)
ipm <- RSiteSearch.function('interior point method')
hits(ipm) # 39
SQP <- RSiteSearch.function('SQP')
hits(SQP) # 2
sqp <- RSiteSearch.function('sequential
how about this
a <- 1:10
b <- 1:10
d <- paste("x","^","{n-1}")
qplot(a,b, xlab=expression(x^{n-1}))+geom_text(aes(4,8, label=d))
On Fri, May 15, 2009 at 10:02 PM, Paul Emberson wrote:
> Hi,
>
> Is there a way of annotating a ggplot plot with mathematical formulae?
>
> I can do
>
> geom_text(aes(
Hi,
Is there a way of annotating a ggplot plot with mathematical formulae?
I can do
geom_text(aes(label="some text", ...
but I can't do
geom_text(aes(label=expression(x^{n-1}), ...
It gives the error
Error: geom_text requires the following missing aesthetics: label
Is there a convenient equ
On Thu, May 14, 2009 at 2:14 PM, Garritt Page wrote:
> Hello,I am using xyplot to try and create a conditional plot. Below is a
> toy example of the type of data I am working with
>
> slevel <- rep(rep(c(0.5,0.9), each=2, times=2), times=2)
>
> tlevel <- rep(rep(c(0.5,0.9), each=4), times=2)
>
>
baptiste auguie-2 wrote:
>
>
> Just a thought:
>
> There was recently a discussion here on the pgfSweave [1] driver ---
> it should be possible to use it in conjunction with XeTeX [2] to
> process the pgf output. Presumably there will be issues of alignment
> and spacing but at least ar
On Thu, May 14, 2009 at 12:14 PM, Garritt Page wrote:
> Hello,I am using xyplot to try and create a conditional plot. Below is a
> toy example of the type of data I am working with
>
> slevel <- rep(rep(c(0.5,0.9), each=2, times=2), times=2)
>
> tlevel <- rep(rep(c(0.5,0.9), each=4), times=2)
>
>
popo UBC wrote:
>
> Hi Charlie,
>
> Thank you so much for suggestions!!
>
> Actually, I used the optimization toolbox in MABLAB before and I even
> wrote
> some numerical optimization programs by myself. As far as I know, some
> commercial optimization softwares had already replaced L-BFGS-B
>
> Hello All,
>
Please help me with this problem.I have been having this problem for over a
month now and I could not find any information.I later realised that error
is with MATRIX package.
I am working on graph object using IGRAPH version 0.5.2-2 package & wanted
to do Bonacich Power.
What I
Dear all,
I have some problems how to increase memory in R.
I tried to start R by calling e.g. :(in the Properties, Shortcut tab, Target
field)
Rgui.exe --max-mem-size=2Gb (Is this correct?)
But the error message still continue:
> X<-princomp(MAT2D.AltGeop61.90)
Error: cannot allocate vect
How can I convert an integer or double to and from their internal
representation as raws of length 4 and 8?
The following works for positive integers (including those represented
as floats):
# Convert integer (represented as integer or double) to sequence
# of raw bytes, least-significant byte fi
On 15 May 2009 at 13:08, G. Jay Kerns wrote:
| Thanks very much to Warren and Stavros for their additional insight.
| Putting all of this together, I think I am now ready to formulate my
| question intelligently:
|
| Using Sweave, I want to distribute randomly generated problems AND
| answers to
On Fri, May 15, 2009 at 12:07 PM, Stavros Macrakis
wrote:
> system.time(whatseed(runif(1)))
Sorry, though I got lucky and my overall result is roughly correct,
this is an incorrect time measure. It should be
r <- runif(1); system.time(whatseed(r))
because R's call-by-need semantics don't e
Hi,
I think "quadratic programming" is the way to go. Look at "solve.QP" or
"limSolve" package.
Here is a toy example that I had worked out some time back for a linear
least squares problem with simple box constraints:
# Problem: minimize ||Ax - y||, subject to low <= x <= upp
require(limSolve
cls59 wrote:
>
> install.packages('pgfSweave',repos='http://www.rforge.net')
>
For others that are not on Linux. I would suggest using the r-forge site for
binary installation. The binaries on rforge.net are not completely up to
date in some cases.
install.packages("pgfSweave", repos="http:/
Thanks guys!
Duncan's hints regarding "character" (which I was naturally using ;0) and
the double "readBin" solved my problem - I'm extracting an index from a
REALLY big XML file to get fast direct access to subsections, so that I only
have to parse them rather than the whole thing (only SAX-st
G. Jay Kerns wrote:
I want it to be *difficult* for students to figure out the seed and
automatically generate solutions on their own.
Hmmm Would it really be a bad thing if someone reverse engineered
this to generate answers given the problem set? If it's hard enough to
do that, it'd b
Thanks, I'll take a look.
Christophe
Le 15 mai 09 à 20:11, Greg Snow a écrit :
> Duncan mentioned the arrows function, which may do everything you
> want. But, also look at the my.symbols function in the
> TeachingDemos package for another way to draw arrows, or to draw
> your circles and
I suggest you try to translate your constraints into an
unconstrained constrained problem using logarithms, then do "nonlinear
mixed effects modeling" as described in chapters 6-8 of Pinheiro and
Bates (2000). To do this, I would first start with the simpler linear
estimation problem to g
Duncan mentioned the arrows function, which may do everything you want. But,
also look at the my.symbols function in the TeachingDemos package for another
way to draw arrows, or to draw your circles and arrows in 1 step.
--
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Hea
Greg Snow wrote:
> Another possibility (maybe more readable, gives the option of a list,
> probably not faster):
>
> Replicate(1000, rexp(15,1) )
>
>
provided that simplify=FALSE:
is(replicate(10, rexp(15, 1)))
# "matrix" ...
is(replicate(10, rexp(15, 1), simplify=FALSE))
# "
The arrow "<-" is used to assign a value to a variable, the equals sign "=" is
used to specify the value for a function argument. Recent versions of R allow
"=" to be used for "<-" at the top level and certain circumstances which some
people find more convenient, but can also lead to confusion
On May 15, 2009, at 12:18 PM, Bill Hudspeth wrote:
Hello,
I am using barplot to generate a histogram of population by county. I
need to plot the bars for about 35 counties, and would like to rotate
the county name labels on the x-axis to a vertical orientation so
that I
can fit them all. An
Hello,
I am using barplot to generate a histogram of population by county. I
need to plot the bars for about 35 counties, and would like to rotate
the county name labels on the x-axis to a vertical orientation so that I
can fit them all. An example of my syntax is below:
r.barplot(x,main=main,
xl
Hi William,
Thanks for the comments and explanation.
It is really good to know the details of rowMeans.
I did modified Peter's codes from length(x[x=="02"]) to sum(x=="02"), though it
improved only in few seconds. :)
Best,
Mike
-Original Message-
From: William Dunlap [mailto:wdun...@tib
I would like to know about any workshops/meetings on the topics of (1) using
some version of BUGS with R (2) resampling methods (3) other advanced
courses.
Thanks for any ideas.
Kevin Wright
[[alternative HTML version deleted]]
__
R-help@r-pro
>
> Set.seed takes an integer argument, that is, 2^32-1 distinct values
> (cf NA_integer_), so the very simplest approach, brute-force search,
> has a hope of working:
>
> whatseed <- function (v) {
> i <- as.integer(-2^31+1); max <- as.integer(2^31-1)
> while (i }
>
>> (OK, being able to figu
Hi,
I would like to draw arrows in a classic 2D plot. Which package should I
use? is there R base functions that do job?
On google, I could not find any useful discussion about this topic, except a
link to the function 'grid.arrows' of the grid package.
My problem is I would like to draw arrows
On 5/15/2009 12:43 PM, christophe dutang wrote:
Hi,
I would like to draw arrows in a classic 2D plot. Which package should I
use? is there R base functions that do job?
On google, I could not find any useful discussion about this topic, except a
link to the function 'grid.arrows' of the grid pa
I wrote "replicate" but the darn e-mail program "fixed" it for me. I expected
replicate to be a bit slower, but not by that amount. I just wanted to include
replicate as a more readable version of lapply while still improving over the
loop approach.
--
Gregory (Greg) L. Snow Ph.D.
Statistica
Thanks for Peter, William, and Hadley's helps.
Your codes are much more concise than mine. :P
Both William and Hadley's comments are the same. Here are their codes.
f <- function(dataMatrix) rowMeans(datamatrix=="02")
And Peter's codes are the following.
apply(yourMatrix, 1, f
On 5/15/2009 9:22 AM, Stefo Ratino wrote:
Hello,
I am using: save(data,file="D:/mayData.RData"), and I have the following error:
Error in save(data, file = "D:/mayData.RData") : error writing to connection
Do you have permission to create a file there? Try it from outside R.
Duncan Murdoc
On May 15, 2009, at 8:22 AM, Stefo Ratino wrote:
Hello,
I am using: save(data,file="D:/mayData.RData"), and I have the
following error:
Error in save(data, file = "D:/mayData.RData") : error writing to
connection
Thank you very much in advance,
Stefo
Presuming that drive 'D' exists an
Thank you both very much for your replies. What makes this a little less
straightforward, at least to me, is that there needs to be constraints on
the solved parameters. They most certainly need to be positive and there
may be an upper limit as well. The true best linear fit would have negative
en
On May 15, 2009, at 10:58 AM, Adrián Cortés wrote:
Hello,
I saw this nice trick I want to replicate but I lost the source and
I hope
one of you can point me to the solution. My problem is that I don't
know
the correct words to query this.
When I print to screen a matrix or data.frame the
> "AC" == Adrián Cortés
> on Fri, 15 May 2009 08:58:04 -0700 writes:
AC> Hello,
AC> I saw this nice trick I want to replicate but I lost the source and I
hope
AC> one of you can point me to the solution. My problem is that I don't
know
AC> the correct words to query
Dear Doug, et al.:
What would you recommend for analyzing a longitudinal abundance
survey of 22 species, when the species were not selected at random? A
prominent scientist tried to tell me that mixed-effects modeling is
inappropriate in that case because the species were selected
pur
Greg Snow wrote:
> Another possibility (maybe more readable, gives the option of a list,
> probably not faster):
>
> Replicate(1000, rexp(15,1) )
>
I think that should be "replicate"
The matrix form is quite a bit faster, but don't know if that will
matter -- times below are for doing this
Dear Avraham:
For problems with many parameters to estimate, I highly recommend
Pinheiro and Bates (2000) Mixed-Effects Models in S and S-Plus
(Springer). This book includes numerous examples showing how to use the
"nlme" package. The value of this book is greatly enhanced by the
Marc Schwartz wrote:
>
> On May 15, 2009, at 9:46 AM, Liviu Andronic wrote:
>
>> Dear all,
>> I'm trying to gsub() "%" with "\%" with no obvious success.
>>> temp1 <- c("mean", "sd", "0%", "25%", "50%", "75%", "100%")
>>> temp1
>> [1] "mean" "sd" "0%" "25%" "50%" "75%" "100%"
>>> gsub
Another possibility (maybe more readable, gives the option of a list, probably
not faster):
Replicate(1000, rexp(15,1) )
--
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.s...@imail.org
801.408.8111
> -Original Message-
> From: r-help-boun...@r-proj
Hi
I'm trying to write a generic script for processing some data which finishes
off with some plots. Given Im never sure how many columns will be in my
dataframe I wanted to using the following
plot(spectra.wavelength, cormat, type = "l", ylim=c(-1,1), xlab="Wavelength
(nm)", ylab="Correlation"
On Thu, May 14, 2009 at 3:36 PM, G. Jay Kerns wrote:
> set.seed(something)
> x <- rnorm(100)
> y <- runif(500)
> # bunch of other stuff
...
> Now, I give you a copy of my script.R (with the set.seed statement
> removed, of course) together with the .RData file that was generated
> by the save.imag
Hello everyone,
(This is my second question posted today on the R list).
I am carrying out a competing risks analysis using the cuminc function...this
takes the form:
cuminc(ftime,fstatus,group)
In my study, fstatus has 3 different causes of failure (1,2,3) there are also
censored cases (0).
Hi
I'm trying to write a generic script for processing some data which finishes
off with some plots. Given Im never sure how many columns will be in my
dataframe I wanted to using the following
plot(spectra.wavelength, cormat, type = "l", ylim=c(-1,1), xlab="Wavelength
(nm)", ylab="Correlation"
Hello,
I am using: save(data,file="D:/mayData.RData"), and I have the following error:
Error in save(data, file = "D:/mayData.RData") : error writing to connection
Thank you very much in advance,
Stefo
[[alternative HTML version deleted]]
Hello,
I saw this nice trick I want to replicate but I lost the source and I hope
one of you can point me to the solution. My problem is that I don't know
the correct words to query this.
When I print to screen a matrix or data.frame the columns are split and
printed below the previous ones; eve
On 15-May-09 14:46:27, Liviu Andronic wrote:
> Dear all,
> I'm trying to gsub() "%" with "\%" with no obvious success.
>> temp1 <- c("mean", "sd", "0%", "25%", "50%", "75%", "100%")
>> temp1
> [1] "mean" "sd" "0%" "25%" "50%" "75%" "100%"
>> gsub("%", "\%", temp1, fixed=TRUE)
> [1] "m
Dear everyone,
My question involves the use of the survival object.
We can have
Surv(time,time2,event, type=, origin = 0)
(1)
As detailed on p.65 of:
http://cran.r-project.org/web/packages/survival/survival.pdf
My data (used in my study) is 'right ce
I would like to preform a t.test to each of the measured variables
(sand.silt etc.) with a mean and sd for each of the treatments (up or
down), and out put this as a table I am having a hard time
starting- maybe it is to close to lunch. Any suggestions would be
greatly appreciated.
Stephen S
On Wed, May 13, 2009 at 5:21 PM, wrote:
>
> Hello.
>
> I am trying to optimize a set of parameters using /optim/ in which the
> actual function to be minimized contains matrix multiplication and is of
> the form:
>
> SUM ((A%*%X - B)^2)
>
> where A is a matrix and X and B are vectors, with X as p
Dear Amit,
The following should get you started. What I'm doing is creating an
identifiers (g) with the "names" of the columns you want to group for and
then use a combination of apply() and tapply() to get the mean for each row
in the levels of g. In your case, you have more columns than I have in
Peter Menzel wrote:
> Hi everyone,
>
> I have a problem with adding points to scatter plots.
> The plot is drawn with the scatterplot() function from the car library:
>
> scatterplot(data[,2] ~ data[,1],
> data=data,smooth=F,reg.line=F,xlim=c(0.5,1),ylim=c(0.5,1),ylab="ML",xlab="Freq",cex.lab=1.9
Thanks all for the prompt responses. Now Hmisc::latex() no longer
generates errors on Rcmdr::numSummary() objects (with `tempa' below
being such an object).
> colnames(tempa$table) <- gsub("%", "\\%", colnames(tempa$table), fixed=TRUE)
> latex(tempa$table, cdec=3)
Best regards,
Liviu
On Fri, May
On Fri, May 15, 2009 at 3:38 PM, Romain Francois
wrote:
> Hi,
>
> You can either parse and eval the string you are making, as in:
>
> eval( parse( text = paste("avg_",colname, " <- 0;", sep='') ) )
>
>
> Or you can do something like this:
>
> df[[ paste( "avg_", colname, sep = "" ) ]] <- 0
>
Than
The original problem posed was:
On 14/05/2009 7:31 AM, Graves, Gregory wrote:
> I have 3 columns: flow, month, and monthname, where month is 1-12,
and
> monthname is name of month. I can't get the plot to replace the 1-12
> with monthname using ticks.lab. What am I doing wrong?
>
> plot(flow
On May 15, 2009, at 9:46 AM, Liviu Andronic wrote:
Dear all,
I'm trying to gsub() "%" with "\%" with no obvious success.
temp1 <- c("mean", "sd", "0%", "25%", "50%", "75%", "100%")
temp1
[1] "mean" "sd" "0%" "25%" "50%" "75%" "100%"
gsub("%", "\%", temp1, fixed=TRUE)
[1] "mean
Hi.
I am trying to model data on movements (direction) of birds and the
response variables are compass directions (0 to 360).
I have found two packages CircStats and Circular that can implement
linear models for a circular response, which will do what I need for
the data set I am currently wor
Dear all,
I'm trying to gsub() "%" with "\%" with no obvious success.
> temp1 <- c("mean", "sd", "0%", "25%", "50%", "75%", "100%")
> temp1
[1] "mean" "sd" "0%" "25%" "50%" "75%" "100%"
> gsub("%", "\%", temp1, fixed=TRUE)
[1] "mean" "sd" "0%" "25%" "50%" "75%" "100%"
Warning m
Hi Deepayan,
Thank you very much for the tip. After removing the 'more' argument and
another couple of hours, I finally found something that works for my
multi-page multi-graph plots. For documentation, the script is:
library(lattice)
library(grid)
foo <- data.frame(x=1:10,y=1:10)
# Defines so
>> Forgive the newbie question, I want to select random rows from my
>> data.frame to create a test set (which I can do) but then I want to
>> create a training set using whats left over.
>>
The caret package has a function, createDataPartition, that does the
split taking into account the distribu
On Fri, 15 May 2009 15:43:33 +0200 Peter Menzel
wrote:
PM> scatterplot(data[,2] ~ data[,1],
PM>
data=data,smooth=F,reg.line=F,xlim=c(0.5,1),ylim=c(0.5,1),ylab="ML",xlab="Freq",cex.lab=1.9,cex.axis=1.8)
Side remark: you don't need do data[,2] if you have specified data=data
as you did. So var1~v
I'm not quite sure what you want to do, but this might help:
d=data.frame(replicate(40, rnorm(20)))
d$sample=rep(c('a','b','c','d'),each=5)
lib(doBy)
summaryBy(.~sample,da=d)
David Freedman
Amit Patel-7 wrote:
>
>
> Hi
> I am trying to create a loop which averages replicates in my data.
> The
On May 15, 2009, at 9:04 AM, Duncan Murdoch wrote:
On 5/15/2009 11:04 AM, meenus...@gmail.com wrote:
Dear all
I was trying to install the package ISwR and got the following
message. I was connected to the internet.
Warning: unable to access index for repository
http://cms.unipune.ernet.in/co
On 5/15/2009 11:04 AM, meenus...@gmail.com wrote:
Dear all
I was trying to install the package ISwR and got the following message. I was
connected to the internet.
Warning: unable to access index for repository
http://cms.unipune.ernet.in/computing/cran/bin/windows/contrib/2.8
That's a proble
Dear all
I was trying to install the package ISwR and got the following message. I was
connected to the internet.
Warning: unable to access index for repository
http://cms.unipune.ernet.in/computing/cran/bin/windows/contrib/2.8
Please help.
regards
M.
__
Hi everyone,
I have a problem with adding points to scatter plots.
The plot is drawn with the scatterplot() function from the car library:
scatterplot(data[,2] ~ data[,1],
data=data,smooth=F,reg.line=F,xlim=c(0.5,1),ylim=c(0.5,1),ylab="ML",xlab="Freq",cex.lab=1.9,cex.axis=1.8)
after that, I draw
Hi,
We are working on R project with the latest version 2.9.0. We are using matplot
and barplot functions to draw different graphs. End user may generate graphs
for large number of data. Also, each point to be plotted may have large name
(around 170 characters). These names (Y axis points) need
Duncan Murdoch wrote:
> On 5/15/2009 8:33 AM, deanj2k wrote:
>> Hi everyone, can anyone tell me how i can change how i display
>> mean(age), i
>> want it to say The mean age of patients within the sample is mean(age)
>
> I think you want something like this:
>
> cat(sprintf("The mean age of patient
Hi,
You can either parse and eval the string you are making, as in:
eval( parse( text = paste("avg_",colname, " <- 0;", sep='') ) )
Or you can do something like this:
df[[ paste( "avg_", colname, sep = "" ) ]] <- 0
Romain
Philipp Schmidt wrote:
Hi:
I very recently started experimenting wi
On 5/15/2009 8:33 AM, deanj2k wrote:
Hi everyone, can anyone tell me how i can change how i display mean(age), i
want it to say The mean age of patients within the sample is mean(age)
I think you want something like this:
cat(sprintf("The mean age of patients within the sample is %.1f.\n",
me
Hi:
I very recently started experimenting with R and am occasionally
running into very basic problems that I can't seem to solve. If there
is an R-newbies forum that is more appropriate for these kinds of
questions, please direct me to it.
I'd like to automatically add vectors to a dataframe. I a
Duncan Murdoch wrote:
1) can you tell me what my original set.seed() value was? (I wouldn't
be able to figure it out, but maybe someone can)
The only way I know is to test all 2^32 possible values of the seed. I
think cryptographers would know faster ways.
Well, I'm not a cryptographer, bu
On May 15, 2009, at 6:57 AM, deanj2k wrote:
hi everyone, wondering if you could help me with a novice problem.
I have a
data frame called subjects with a height and weight variable and
want to
calculate a bmi variable from the two. i have tried:
attach(subjects)
bmi <- (weight)/((height
--- On Fri, 15/5/09, Amit Patel wrote:
> From: Amit Patel
> Subject: Help with loops
> To: r-help@r-project.org
> Date: Friday, 15 May, 2009, 12:17 PM
> Hi
> I am trying to create a loop which averages replicates in
> my data.
> The original data has many rows. and consists of 40 column
> zz[
Dear H Z,
Take a look at the examples in
require(MASS)
?glm.nb
This might be useful as well
summary(glm.nb(yourvariable ~ 1, data = yourdata))
HTH,
Jorge
On Fri, May 15, 2009 at 7:26 AM, H Z wrote:
> Dear all
> please ,I need to write a function in R to estimate the parameters of
> negativ
Absolutely no idea what you mean,
Try reconstructing your question in concise English with reproducible code.
Simon.
- Original Message -
From: "deanj2k"
To:
Sent: Friday, May 15, 2009 1:33 PM
Subject: [R] displaying results
Hi everyone, can anyone tell me how i can change how
Dear list members,
I was out of town when this message arrived and so didn't respond at the
time. I did respond to a private email from the poster.
Yes, the scatter3d() function in the Rcmdr package can identify points in 3D
scatterplots drawn with rgl via the identify3d() function in the same
pa
Here's one possibility:
idx <- sample(nrow(acc))
training <- acc[idx[1:400], ]
testset <- acc[-idx[1:400], ]
Andy
From: Chris Arthur
>
> Forgive the newbie question, I want to select random rows from my
> data.frame to create a test set (which I can do) but then I want to
> create a training
Read about glm by typing
?glm
There are tons of books and pdfs out there to show you the basics.
http://cran.r-project.org/other-docs.html
HTH, Si.
- Original Message -
From: "H Z"
To:
Sent: Friday, May 15, 2009 12:26 PM
Subject: [R] need help
Dear all
please ,I need to write
Read the posting guide please. Self-contained, minimal, reproducible code.
On Fri, May 15, 2009 at 8:33 AM, deanj2k wrote:
>
> Hi everyone, can anyone tell me how i can change how i display mean(age), i
> want it to say The mean age of patients within the sample is mean(age)
> --
> View this mes
M <- (structure(list(date = structure(c(13634, 13665, 13695, 13726,
13757, 13787, 13818, 13848, 13879, 13910, 13939, 13970, 14000,
14031, 14061, 14092, 14123, 14153, 14184, 14214, 14245, 14276,
14304, 14335), class = "Date"), cospi = c(1987.31, 2033.37, 2140.13,
2120.66, 2427.09, 2917.7, 2915.28, 3
On Fri, 15 May 2009 19:17:37 +1000 Kon Knafelman
wrote:
KK> I hve the same problem as the initial one, except i need 1000
KK> samples of size 15, and my distribution is Exp(1). I've adjusted
KK> some of the loop formulas for my n=15, but im unsure how to proceed
KK> in the quickest way.
KK> Ca
Hi everyone, can anyone tell me how i can change how i display mean(age), i
want it to say The mean age of patients within the sample is mean(age)
--
View this message in context:
http://www.nabble.com/displaying-results-tp23558890p23558890.html
Sent from the R help mailing list archive at Nabbl
as.numeric() doesn't convert factors to the explicit value, nor should
it. Under what you're expecting, ff you have a factor where the levels
are "Female" and "Male", using as.numeric() wouldn't produce anything
meaningful.
However, as.numeric() does something much smarter. It converts "Female"
Note that the single split sample technique is not competitive with
other approaches unless the sample size exceeds around 20,000.
Frank
Chris Arthur wrote:
Forgive the newbie question, I want to select random rows from my
data.frame to create a test set (which I can do) but then I want to
c
Dear Kushantha,
Thank you very much.
Very nice, indeed.
Gabor
__
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
Thanks Jorge,
but I still don't understand where they come from. when I use:
fitdistr(mydata, "t", df = 9) and get values for m and s, and the variance
of my data should be the df/s?
I jsut want to be able to confirm how m and s are calculated
mydt <- function(x, m, s, df) dt((x-m)/s, df)/s
f
Dear all
please ,I need to write a function in R to estimate the parameters of negative
binomial distribution and then calculate the loglikelihood amount for given
data.Is there any one to help me.
thank you very much for any help
Best regards
[[alternative HTML version deleted
hi everyone, wondering if you could help me with a novice problem. I have a
data frame called subjects with a height and weight variable and want to
calculate a bmi variable from the two. i have tried:
attach(subjects)
bmi <- (weight)/((height/100)^2)
but it comes up with the error:
Warning me
Hi
I am trying to create a loop which averages replicates in my data.
The original data has many rows. and consists of 40 column zz[,2:41] plus row
headings in zz[,1]
I am trying to average each set of values (i.e. zz[1,2:3] averaged and placed
in average_value[1,2] and so on.
below is my script
1. Might you look again at section "2. Maximum likelihood
estimation" of the "dlm" vignette? It describes how to estimate
parameters.
2. Have you started with the code on those 2 pages, confirming
that you can make that work and understand what it does? If yes, then
try to
On Thu, 14 May 2009 12:32:18 -0700 (PDT) PDXRugger
wrote:
P>
P> Alright, i am unsure of the posting rules for these types of
P> questions but i will be as help ful as possible. My windows based
P> system cant handle a model i am running so i am trying to install R
Why? To many data?
P> on our
I have studied both the vinguette and other material I've been able to get my
hands on and Im starting to get a better understanding. And I'm defenitly
going to buy Petris, Petrone, and Campagnoli (2009) Dynamic Linear Models
with R. But that's not publish yet so I 'm not getting much help there.
Introducing the Intel® Core™2 Quad processor for desktop PCs, designed
to handle massive compute and visualization workloads enabled by
powerful multi-core technology. Providing all the bandwidth you need
for next-generation highly-threaded applications, the latest four-core
Intel Core 2 Quad proce
Forgive the newbie question, I want to select random rows from my
data.frame to create a test set (which I can do) but then I want to
create a training set using whats left over.
Example code:
acc <- read.table("accOUT.txt", header=T, sep = ",", row.names=1)
#select 400 random rows in data
trai
Introducing the Intel® Core™2 Quad processor for desktop PCs, designed
to handle massive compute and visualization workloads enabled by
powerful multi-core technology. Providing all the bandwidth you need
for next-generation highly-threaded applications, the latest four-core
Intel Core 2 Quad proce
1 - 100 of 112 matches
Mail list logo