is it possible to map 2 plots(c and d) in a single output plot?
library(ggplot2)
c <- ggplot(mtcars, aes(qsec, wt))
d <- ggplot (mtcars, aes(qsec, wt))
c + stat_smooth(fill="darkgrey", colour="blue", size=2, alpha = 0.2)
d + stat_smooth(fill="darkgrey", colour="red", size=2, alpha = 0.2)
--
View
The playSudoku function in the Sudoku package reacts to keypresses using
windows or Tk, you can use that as an example.
--
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-projec
On Fri, 13 Aug 2010, fishkbob wrote:
So I have a bunch of c(start,end) points and want to consolidate them into as
few c(start,end) as possible.
For example:
sample startend
A 5 10
B 7 18
C 14
D 16 20
I'd want
Hi Chris,
Thanks for your advice which works for me here.
I'm reading;
An Introduction to R
http://h1.mg4.mail.yahoo.com/dc/launch?sysreq=ignore
NOT finish yet. Also I found many tutorials on Internet. I'll take me time
going through all of them.
I'm interesting reading tutorial with demo.
On Aug 13, 2010, at 6:57 PM, chantalm wrote:
So I have a for loop
for (i in 1 : 5) {
print(i)
}
and I want it to print 1, 2, 3, 4, 5 sequentially for each loop
iteration.
Instead, it waits for the whole loop to finish and then prints. It's
strange
because my R console seems to have two m
On Aug 13, 2010, at 11:25 PM, Duncan Mackay wrote:
Hi David
I do not know if you have done something like this.
I had tried a few efforts like that, starting with an examination of
str(bp.plot) as you demonstrate.
I tried str(bp.plot) which gave the section about the regions (for
colou
On Aug 13, 2010, at 4:06 PM, fishkbob wrote:
list<-seq(2,10,2)
list
[1] 2 4 6 8 10
list[-which(2==list)]
[1] 4 6 8 10
using the which() will let you remove things from a list that have a
specified value... I usually use the
blah<- blah[-which(TRUE==is.na(blah)) ]
which will remov
What your saying is true. The sequential/marginal difference can account for
the discrepancy in p values but not necessarily the coefficients. One thing
I've found that can lead to differences in coefficients and p values between R
and SPSS is whether or not you specify that a variable is a fa
Hi David
I do not know if you have done something like this.
I tried str(bp.plot) which gave the section about the regions (for colours) as:
$ panel.args.common:List of 8
..$ x : num [1:2500] 27 28 29 29.9 30.9 ...
..$ y : num [1:2500] 141 141 141 141 141 ...
..$ z : num [1:
Hi JesperHybel,
Thanks for your advice.
>If you're trying to follow the youtube video you have a typing mistake here:
>InsectSprays.aov <-(test01$count ~ test01$spray)
>I think this should be:
>InsectSprays.aov <-aov(test01$count ~ test01$spray)
Your advice works for me. Sorry I missed "aov
Yes, but ... the original poster said the coefficients differed too.
(The blog post
you refer to deals with ANOVA (i.e. linear models) rather than GLMs (generalized
linear models): it is true that the sequential/marginal
distinction still applies, but I don't think that can be the *only*
thing
R usesType I sequential SS, not the default Type III marginal SS reported by
SPSS. There is a good blog post explaining this difference along with some
interesting comments --
http://myowelt.blogspot.com/2008/05/obtaining-same-anova-results-in-r-as-in.html
Best Wishes,
Martin H. Teicher
Dept
elaine kuo gmail.com> writes:
> Pls kindly advise what scaling is in plot.
> Sometime it could be negative but sometimes it might be positive
> .(I guess it is the proportion between the plot and the margin)
Your question is unclear. Please give more context and/or details.
__
Martin Teicher hms.harvard.edu> writes:
> I'm relatively new to r. I'd like to have a user respond by
> pressing a 1 or a 2 and determining their choice and
> the time of response. Previous postings have indicated that
> keyboard responses can be processed using
> scan and readline but both se
Dear List,
I am running constrained correspondence analysis for abundance data of 7
birds.
However, I would like to check which bird prefers which environment gradient
by showing the species with different colors of the dots in cca plot
(package vegan).
Please kindly help and thank you
Elaine
Dear List,
Pls kindly advise what scaling is in plot.
Sometime it could be negative but sometimes it might be positive
.(I guess it is the proportion between the plot and the margin)
Thanks
Elaine
[[alternative HTML version deleted]]
__
R-hel
Leo Vorthoren nioo.knaw.nl> writes:
> I have been using generalized linear models in SPSS 18, in order to build
> models and to calculate the P values. When I was building models in Excel
> (using the intercept and Bs from SPSS), I noticed that the graphs differed
> from my expectations. When I r
Hi Folks,
I'm relatively new to r. I'd like to have a user respond by pressing a 1 or a
2 and determining their choice and the time of response. Previous postings
have indicated that keyboard responses can be processed using scan and readline
but both seem to wait for the user to also press r
OK, I've added a 'horizontal' argument to panel.xyarea(), which is
consistent with the meaning in panel.xyplot(). It is available from
R-forge via SVN now, or as a built package within a day or 2 probably.
Questions like this are best sent to package maintainers directly, I think.
Regards
# Felix
- Original Message
From: "Liaw, Andy"
To: Stephen Liu ; r-help@r-project.org
Sent: Sat, August 14, 2010 12:48:33 AM
Subject: RE: [R] Learning ANOVA
>Note the names of the variables here. They don't match what you tried
>to use in your boxplot() call below. Where did you get the idea t
Try to do this
> list <- seq(1,5,1)
> list<-list[-3]
> list
[1] 1 2 4 5
list[-x] will remove the xth value in your list. Also you can do something
like
> list[-c(1:4)]
[1] 5
To remove values at indexes 1-4
> list[-c(1,4)]
[1] 2 3 5
To remove values at indexes 1 and 4
--
View this message in
So I have a bunch of c(start,end) points and want to consolidate them into as
few c(start,end) as possible.
For example:
sample startend
A 5 10
B 7 18
C 14
D 16 20
I'd want the function to return the two distinct
"or an incompetent"
Such harsh words Peter. You're not making this a friendly environment for
people to ask questions. Is there a less competent attribute mailing list so
that some of us don't offend you with our questions?
On Aug 13, 2010, at 2:11 PM, Peter Dalgaard wrote:
Andrea Franceschini
> list<-seq(2,10,2)
> list
[1] 2 4 6 8 10
> list[-which(2==list)]
[1] 4 6 8 10
using the which() will let you remove things from a list that have a
specified value... I usually use the
blah<- blah[-which(TRUE==is.na(blah)) ]
which will remove all NA values in your list
--
View this mes
So I have a for loop
for (i in 1 : 5) {
print(i)
}
and I want it to print 1, 2, 3, 4, 5 sequentially for each loop iteration.
Instead, it waits for the whole loop to finish and then prints. It's strange
because my R console seems to have two modes of execution. One where it will
iterate for each
Please,when i export the output from R to excel.I am not getting all the
15,000 observations but only 2000.Thank you
--
View this message in context:
http://r.789695.n4.nabble.com/help-tp2323542p2324459.html
Sent from the Export many data to Excel 2007 mailing list archive at Nabble.com.
__
I have a plot produced by function bplot (package = rms) that is
really a lattice plot (class="trellis"). It is similar to this plot
produced by a very minor modification of the first example on the
bplot help page:
requiere(rms)
n <- 1000# define sample size
set.seed(17) # so can rep
(Ted Harding) wrote:
> Johannes' original query was about differences when there
> are NAs, corresponding to different settings of "na.action".
> It is perhaps possible that 'na.action="na.pass"' and
> 'na.action="na.exclude"' result in different pairings in the
> case "paired=TRUE". However, it s
Hi Thomas,
I'm not too sure about your interpretation. Consider:
set.seed(54321)
X <- rnorm(10) ; Y <- rnorm(10)
XY <- c(X,Y); group<-c(rep(0,10),rep(1,10))
t.test(X,Y,paired=TRUE)
# Paired t-test
# data: X and Y
# t = -1.5265, df = 9, p-value = 0.1612
# 95 percent confi
Other terms for Kalman filtering, prediction and smoothing are
"state space modeling" and "dynamic linear models".
Consider the following extension of Ben Bolker's suggestion to
use the 'sos' package:
library(sos)
k <- ???Kalman
ss <- findFn('state space')
dlm <- findFn('dynami
Neither you nor your responder have continued the eamil chain very
well so let me put things back together:
on Aug 13, 2010; 03:54pm fishkbob wrote subj = merge function in R?
So I have a bunch of c(start,end) points and want to consolidate
them into as few c(start,end) as possible.
For ex
I figured it out myself, here it is: control=rpart.control(cp=.001))
Thank you!
On Fri, Aug 13, 2010 at 12:58 PM, Olga Shaganova wrote:
> My decision tree grows only with one split and based on what I see in
> E-Miner it should split on more variables. How can I adjust splitting
> criteria in R
I too think I worded it incorrectly...
so the second two columns of the matrix are the start and end of an interval
however, because some of the intervals overlap, I want to limit the number
of intervals I have to deal with.
So therefore,
(5 10)should merge with(7 18) making
I think it would be helpful if you could clarify youre question - do you want
distinct sets - maybe use
unique()
but why (5,20) when its (5,10) in the row in youre example? What criteria do
you want the function to select the "sets" by and what kind of output do you
need?
Maybe it's just me w
Thank you for the fast reply! Although I have read the help page for
t.test over and over again I have obviously overlooked the relevant
sentence. The "workaround" that I have planned seems to be the
correct use.
Thanks again,
J. W. D.
At 15:31 Uhr -0700 13.08.2010, Thomas Lumley wrote:
Than
Thanks for the clear example. However, if there is a bug it is only that
t.test.formula doesn't throw an error when given the paired=TRUE option.
The documentation says "The formula interface is only applicable for the 2-sample
tests.", but there probably should be an explicit check -- I did
Installing rJava fails consistently, whether installed via
the command line as below, or through "install.packages(
'rJava' )", and whether 0.84 or 0.85 is used, with the
message :-
"checking JNI data types... configure: error: One or more
JNI types differ from the corresponding native type. You ma
Hello,
I need to plot the means of some outcome for two groups (control vs
intervention) over time (discrete) on the same plot, for various subsets
such as gender and grade level. What I have been doing is creating all
possible subsets first, using the aggregate function to create the means
over
Hello all,
due to unexplained differences between statistical results from
collaborators and our lab that arose in the same large proteomics
dataset we reevaluated the t.test() function. Here, we found a weird
behaviour that is also reproducible in the following small test
dataset:
Suppose,
On Fri, Aug 13, 2010 at 5:32 PM, Gabor Grothendieck
wrote:
> On Fri, Aug 13, 2010 at 5:21 PM, Dennis Fisher wrote:
>> Colleagues,
>>
>> I am using "nls" successfully (2.11.1, OS X) but I am having difficulties
>> retrieving part of the output - residual sum of squares. I have assigned
>> the o
Hi, Dennis,
Does this give what you want?
>sum(resid(FIT)^2)
Jun
Senior Pharmacokineticist
Seventh Wave Labs
On Fri, Aug 13, 2010 at 4:21 PM, Dennis Fisher wrote:
> Colleagues,
>
> I am using "nls" successfully (2.11.1, OS X) but I am having difficulties
> retrieving part of the output - resi
On Fri, Aug 13, 2010 at 5:21 PM, Dennis Fisher wrote:
> Colleagues,
>
> I am using "nls" successfully (2.11.1, OS X) but I am having difficulties
> retrieving part of the output - residual sum of squares. I have assigned the
> output to FIT:
>> > FIT
>> Nonlinear regression model
>> model: N
Colleagues,
I am using "nls" successfully (2.11.1, OS X) but I am having difficulties
retrieving part of the output - residual sum of squares. I have assigned the
output to FIT:
> > FIT
> Nonlinear regression model
> model: NEWY ~ PMESOR + PAMPLITUDE * cos(2 * pi * (NEWX - POFFSET)/PERIOD)
Andrea Franceschini wrote:
> I ask the question also because I found this line in Wikipedia:
> "The test (see above) based on the hypergeometric distribution
> (hypergeometric test) is identical to the corresponding one-tailed
> version of Fisher's exact test".
>
> Is this wrong ? May I kindly as
Take a look on this
Packages:
- KFTRACK
- UKFSST
- TRACKIT
2010/8/13 FMH
> Dear All,
>
> Could anyone give me a hand to suggest few packages in R to running Kalman
> prediction and filtration ?
>
> Thanks
> Fir
>
>
>
>
> __
> R-help@r-project.org m
Hi Yvonnick,
Have you looked at ggplot2? There are two examples at the end of [1].
HTH,
Jorge
[1] http://had.co.nz/ggplot2/geom_histogram.html
On Fri, Aug 13, 2010 at 4:12 PM, Yvonnick NOEL <> wrote:
> Dear users,
>
> I would like to plot several histograms superimposed on the same panel
>
Dear users,
I would like to plot several histograms superimposed on the same panel
with different colors, with superimposed polygons appearing with
transparency effects. I also want estimated densities to appear on the
same plot. For several reasons, including that I like it, I want to use
the lat
On 8/13/2010 11:08 AM, Hosack, Michael wrote:
R Experts,
I would like to create a series of variables without having
to assign a separate line of code for each new variable. My dataframe (DF)
contains
two groups of linked variables (ESP1:ESP9) and (ECRL1:ECRL9). Within ESP1:ESP9
are
abbreviate
But in your comment, it sounded like you were in the realm of ANOVA when you
made the degrees of freedom comment. I'm not going to get into the theory of
statistics with you :) I'm just trying to learn R, take it easy. Yes, I
understand that in the regression problem, the degrees of freedom for
My decision tree grows only with one split and based on what I see in
E-Miner it should split on more variables. How can I adjust splitting
criteria in R?
Also is there way to indicate that some variables are binary, like variable
Info_G is binary so in the results would be nice to see "2) Info_G=
# I wasn't trying to do ANOVA. I was simply trying to figure out how regress
count on sprays (this is after I saw another poster asking an unrelated
question with the InsectSprays dataset).
#
# Anyhow, David clarified this but also, thanks for your explanation as well.
rm(list = ls()); sprays <
myFrame$year<-years(strptime(x))
On Fri, Aug 13, 2010 at 12:36 PM, Dimitri Liakhovitski
wrote:
> Hello!
>
> If I have in my data frame MyFrame a variable saved as a Date and want
> to translate it into years, I currently do it like this using "zoo":
>
> library(zoo)
> as.year <- function(x) as.nu
On Aug 13, 2010, at 3:36 PM, Dimitri Liakhovitski wrote:
Hello!
If I have in my data frame MyFrame a variable saved as a Date and want
to translate it into years, I currently do it like this using "zoo":
library(zoo)
as.year <- function(x) as.numeric(floor(as.yearmon(x)))
myFrame$year<-as.yea
You've tried:
as.numeric(format(Sys.Date(), '%Y'))
On Fri, Aug 13, 2010 at 4:36 PM, Dimitri Liakhovitski <
dimitri.liakhovit...@gmail.com> wrote:
> Hello!
>
> If I have in my data frame MyFrame a variable saved as a Date and want
> to translate it into years, I currently do it like this using "
Hello!
If I have in my data frame MyFrame a variable saved as a Date and want
to translate it into years, I currently do it like this using "zoo":
library(zoo)
as.year <- function(x) as.numeric(floor(as.yearmon(x)))
myFrame$year<-as.year(myFrame$date)
Is there a function that would do it directl
So you want 1 degree of freedom for InsectSprays? You believe that the
difference between A and B is exactly the same as between B and C which is
exactly the same as between D and E (etc.)? that seems an odd assumption, but
you can get that by using as.numeric (as I and others have already sta
have a look at function all() but also at function all.equal() -- for
your example,
x1 <- c(1,2,3)
x2 <- c(1,2,3)
x3 <- c(1,2,5)
all(x1 == x2)
all(x1 == x3)
# this safer
isTRUE(all.equal(x1, x2))
isTRUE(all.equal(x1, x3))
I hope it helps.
Best,
Dimitris
On 8/13/2010 8:49 PM, Downey, Patri
all(c(1, 2, 3) %in% c(1,2,3))
On Fri, Aug 13, 2010 at 3:49 PM, Downey, Patrick wrote:
> Hello,
>
> Is there a way to get a single TRUE or FALSE statement from comparing two
> vectors? For example,
> c(1,2,3) == c(1,2,3)
> produces
> TRUE TRUE TRUE
>
> where I would like it to produce only
> TRUE
Patrick,
See all(). For example,
> all(c(1,2,3)==c(1,2,3))
[1] TRUE
> all(c(1,2,3)==c(2,1,3))
[1] FALSE
> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-
> project.org] On Behalf Of Downey, Patrick
> Sent: Friday, August 13, 2010 1:49 PM
> To: r-help@r
Hi Mitch,
How about identical()?
> identical(c(1,2,3), c(1,2,5))
[1] FALSE
> identical(c(1,2,3), c(1,2,3))
[1] TRUE
See ?identical and ?all.equal for more information.
HTH,
Jorge
On Fri, Aug 13, 2010 at 2:49 PM, Downey, Patrick <> wrote:
> Hello,
>
> Is there a way to get a single TRUE or FA
?all
- Phil Spector
Statistical Computing Facility
Department of Statistics
UC Berkeley
spec.
?all
nikhil.l...@gmail.com
On Aug 13, 2010, at 2:49 PM, Downey, Patrick wrote:
c(1,2,3) == c(1,2,3)
__
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
Comments inline below.
-- Bert
On Fri, Aug 13, 2010 at 11:04 AM, Biau David wrote:
> This is all very interesting indeed.
>
> so I appreciate that the effect of a variable will depend on the presence of
> other variables and that the effect of this variable has a statistical
> meaning only in a
Hello,
Is there a way to get a single TRUE or FALSE statement from comparing two
vectors? For example,
c(1,2,3) == c(1,2,3)
produces
TRUE TRUE TRUE
where I would like it to produce only
TRUE
for use in an if statement.
Likewise, when two vectors are not exactly identical (in all elements) I
w
Frank E Harrell Jr Professor and ChairmanSchool of Medicine
Department of Biostatistics Vanderbilt University
On Fri, 13 Aug 2010, Biau David wrote:
This is all very interesting indeed.
so I appreciate that the effect of a variable will depend on the
presenc
If you're trying to follow the youtube video you have a typing mistake here:
InsectSprays.aov <-(test01$count ~ test01$spray)
I think this should be:
InsectSprays.aov <-aov(test01$count ~ test01$spray)
youre missing the functioncall "aov" on the right hand side of the
assignment operator '<-'
R Experts,
I would like to create a series of variables without having
to assign a separate line of code for each new variable. My dataframe (DF)
contains
two groups of linked variables (ESP1:ESP9) and (ECRL1:ECRL9). Within ESP1:ESP9
are
abbreviated species codes (full dataframe contains 26 co
This is all very interesting indeed.
so I appreciate that the effect of a variable will depend on the presence of
other variables and that the effect of this variable has a statistical meaning
only in a specific model. With the particularity of inconsistency if data arise
from non normal distri
Why would you want to do this? Confidence intervals tell you about the
uncertainty of the mean of y give x, not the individual data points. It may
make more sense to use prediction intervals that tell you about individuals
rather than means, but that still means throwing away alpha% of legitim
Dear all,
I was wondering if there is a simple way to avoid printing the multiple
cross-validation automatic output to the console of recursive partitionning
functions like rpart or mvpart. For example...
> data(spider)
>
mvpart(data.matrix(spider[,1:12])~herbs+reft+moss+sand+twigs+water,spider,x
Read documentation for TukeyHSD by typing the command:
?TukeyHSD
The input to that function should usually be, "a fitted model object,
usually an aov fit."
You have not created a "fitted model object."
This seems to work:
model <- aov(InsectSprays$count ~ InsectSprays$spray)
TukeyHSD(model)
T
# Greg, if R automatically does that then I don't know why it's treating each
indicator
# as a different regressor. In other words, I am interested in treating 'spray'
as one
# independent variable.
#
# Erik, which book do you suggest I read? Thanks.
data(InsectSprays)
lm(InsectSprays$count ~ 0
If you just want to visualize the effect on one variable on the response from
some different models then you might try Predict.Plot from the TeachingDemos
package. It takes a little tweaking to get it to work with cph objects, but
here is a basic example (partly stolen from the help page for cp
On Aug 13, 2010, at 1:22 PM, TGS wrote:
To clarify, I'd like to create a column of indicators for the
respective letters so that I could maybe do regression on
indicators, etc.
You can just enter that column name in a regression formula. No need
to create a separate variable. Try:
lm(c
I need to read a data set that has multiple observations per person (like
scanner panel data). I want to use optim and compute the objective function
person by person where each person has multiple observations (as in latent
class models a la Kamakura and Russell (JMR, 1989))? I tried to use the
(
I just tried to do the same task (see beloew) using the rcom package. This
works fine (see below).
Still I would like to now how this can be done using RDCOMClient.
TIA, Mark
library(rcom)
ppt <- comCreateObject("PowerPoint.Application")
pres <- comInvoke(comGetProperty(ppt, "Presentations"), "A
TGS wrote:
To clarify, I'd like to create a column of indicators for the
respective letters so that I could maybe do regression on indicators,
etc.
For instance, "A" gets "1", "B" gets "2", and so on.
That's precisely how factors are handled by modeling functions in R!
No need to reinvent th
R/S does all of that automatically for you, you do not need to manually create
the indicator variables.
If you do something like:
> fit <- lm( Sepal.Width ~ Species, data=iris, x=TRUE)
Then look at the matrix actually used:
> fit$x
Or the output:
> summary(fit)
You will see that Species was
Giovanni Petris wrote:
I am trying to install R-2.11.1 from sources on Ubuntu 10.04.
Any particular reason? There are Ubuntu packages available...
I am
getting the following error when I run ./configure:
configure:6683: checking how to run the C preprocessor
configure:6753: result: gcc -E
Hello.
I´m studing extreme values and i´m using the packages: evd, fExtremes and
evir.
I need to convet timeSeries (or data.frame) to class "POSIXct". Like "bmw"
data:
> is(bmw)
[1] "numeric" "vector" "index_timeSeries"
Please help!!
Thank you
[[alternative HTML version deleted]]
__
I am trying to install R-2.11.1 from sources on Ubuntu 10.04. I am
getting the following error when I run ./configure:
configure:6683: checking how to run the C preprocessor
configure:6753: result: gcc -E
configure:6773: gcc -E -I/usr/local/include conftest.c
configure:6773: $? = 0
configure:6787
FMH yahoo.com> writes:
>
> Dear All,
>
> Could anyone give me a hand to suggest few packages in R to running Kalman
> prediction and filtration ?
Teach a person to fish ...
install.packages("sos")
library(sos)
findFn("kalman")
## perhaps this could be added to the posting guide?
To clarify, I'd like to create a column of indicators for the respective
letters so that I could maybe do regression on indicators, etc.
For instance, "A" gets "1", "B" gets "2", and so on.
On Aug 13, 2010, at 10:19 AM, David Winsemius wrote:
On Aug 13, 2010, at 1:03 PM, TGS wrote:
> # how wo
How about:
tmp <- expand.grid(one = 1:11, two = 1:11)
tmp$week <- ( ( tmp$one + tmp$two ) %% 11 ) + 1
# reformat for simplicity
tmp2 <- tmp[ order(tmp$week), ]
tmp3 <- tmp2[ tmp2$one < tmp2$two , ]
### do some checks to make sure everyone plays everyone
###exactly once and each team plays
On Aug 13, 2010, at 1:03 PM, TGS wrote:
# how would I code in R to look at the letter of the alphabet
# in the second column and create a indicator column for the
# corresponding letter?
data(InsectSprays)
InsectSprays$spray
It's already what most people mean when they say "indicator column"
# how would I code in R to look at the letter of the alphabet
# in the second column and create a indicator column for the
# corresponding letter?
data(InsectSprays)
InsectSprays$spray
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/li
On Fri, Aug 13, 2010 at 12:26 PM, Eva Nordstrom wrote:
> Is there a "more efficient/elegant" way to obtain the result "z" below.
>
> a <- c('pink','pink','blue','blue','gold','gold')
> b <- c(5,8,9,12,7,4)
> agg <- aggregate(x=b,by=list(a), FUN='mean')
> m <- match(a, agg[,1])
> z <- agg[m,2]
> z
Hey everyone,
I don't have a question. Instead some helpful advice with things I've
learned from trying to connect 'R' to databases using RODBC.
ROBDC is a very handy tool that, once you have everything fixed up
nicely, is a great way to have scripts run fairly autonomously, safe in the
Hi Erik,
I followed following video as example;
ANOVA in R
http://www.youtube.com/watch?v=Dwd3ha0P8uw&feature=related
Now I got it done;
> boxplot(test01$count ~ test01$spray)
Continued:
> InsectSprays.aov <-(test01$count ~ test01$spray)
> summary(InsectSprays.aov)
Length ClassMode
From: Stephen Liu
>
> Hi folks,
>
> R on Ubuntu 10.04 64 bit.
>
> Performed following steps on R:-
>
> ### to access to the object
> > data(InsectSprays)
>
> ### create a .csv file
> > write.csv(InsectSprays, "InsectSpraysCopy.csv")
>
>
> On another terminal
> $ sudo updatedb
> $ locate Inse
Steffen--
You might want to take a look at the MCMCglmm package by Jarrod
Hadfield. It can run a zero-inflated overdispersed Poisson model with
random-effects. (I realize you asked about a fixed-effects model, but
MCMCglmm ought to functionally give you what you want -- an appropriate
mode
I try to produce and modify shapes in a PowerPoint presentation but run into a
difficulty setting a variable.
library(RDCOMClient)# load
RDCOMClient package
library(SWinTypeLibs) # package
SWinTypeLibs from Om
Is there a "more efficient/elegant" way to obtain the result "z" below.
a <- c('pink','pink','blue','blue','gold','gold')
b <- c(5,8,9,12,7,4)
agg <- aggregate(x=b,by=list(a), FUN='mean')
m <- match(a, agg[,1])
z <- agg[m,2]
z
[[alternative HTML version deleted]]
___
Just to amplify a bit on what Frank said...
Except in special circumstances (othogonal designs, say), regression
models are only "guaranteed" to produce useful predictions -- they may
not tell you anything meaningful about the relative effects of the
regressors because, as Frank said, that depends
Awesome, that works great, and it cuts my runtime down by a lot.
thanks baptiste
I totally forgot that I could just check to see if the number was inbetween
via less than and greater than rather than having to construct the vector.
findInterval also helps with another problem I was having somew
Performed following steps on R:-
### to access to the object
data(InsectSprays)
### create a .csv file
write.csv(InsectSprays, "InsectSpraysCopy.csv")
On another terminal
$ sudo updatedb
$ locate InsectSpraysCopy.csv
/home/userA/InsectSpraysCopy.csv
### Read in some data
test01 <- re
Hi folks,
R on Ubuntu 10.04 64 bit.
Performed following steps on R:-
### to access to the object
> data(InsectSprays)
### create a .csv file
> write.csv(InsectSprays, "InsectSpraysCopy.csv")
On another terminal
$ sudo updatedb
$ locate InsectSpraysCopy.csv
/home/userA/InsectSpraysCopy.csv
#
I ask the question also because I found this line in Wikipedia:
"The test (see above) based on the hypergeometric distribution
(hypergeometric test) is identical to the corresponding one-tailed
version of Fisher's exact test".
Is this wrong ? May I kindly ask a friendly explanation for
not-exper
Silvano uel.br> writes:
>
> Hi,
>
> I want to build the table of a football league with 11
> teams. All play together. So will 55 games.
> Since there are an odd number of teams in each round a team
> will not play.
The easy solution is moving around a table with one team pausing.
#
On Aug 13, 2010, at 5:15 PM, peter dalgaard wrote:
>
> On Aug 13, 2010, at 4:45 PM, Michael Bedward wrote:
>
>> teams <- LETTERS[1:11]
>> matches <- combn(teams, 2)
>> draw <- data.frame(team1=matches[1,], team2=matches[2,])
>>
>> # someone will know how to do this in one line...
>> time <- nu
1 - 100 of 143 matches
Mail list logo