RTFM time: what do you think the description of 'file' in ?scan says
about devices (I can see nothing that says they are supported). It
does however say that
As from R 2.10.0 this can be a compressed file (see ‘file’).
which is a clear indication of what changed in R 2.10.0. Did yo
This is as documented on the help page for Ops (the page in base, not
the one in Methods) which is linked from ?"|". For background you
should also read the reference on that help page.
You are wrong in asserting that the internal method is 'for logicals':
please do study the help page. It c
Dear Baptiste,
Thanks a lot for the excellent example, which convinced me to start
studying ggplot2.
A trivial question: is there an easy way to generate a boxplot without
outliers?
Using R standard plotting facilities, this amounts to giving
outline=FALSE within boxplot.
Can I easily achieve t
Dear All,
I am trying to stitch together multiple plots using ggplot2
Consider for instance the following snippet based on an old thread
(http://tinyurl.com/ylehm2t)
library(ggplot2)
vplayout <- function(x, y) viewport(layout.pos.row=x, layout.pos.col=y)
draw4 <- function(pdfname, a,b,c,d,w,h) {
R 2.8.1
windows XP
I am trying to learn how to use the boot function to perform a bootstrap of a
regression. I have written a short trial program, shown below. Clearly I have
done something wrong as the output of each of the 100 bootstrap values for the
regression are exactly the same - there d
Hi,
You can set up a Grid layout with one viewport at the bottom and
another on the left and use grid.text to add your labels. An example
is given below using grid.pack.
The gridExtra package provides a convenient wrapper for these regular
arrangements of plots,
##library(gridExtra) #http://grid
Hi,
I ran a negative binomial regression (NBR) using the Zelig-package and the
negbin model.
When I then try to use the simumlation approach using the setx () and sim()
functions to calculate expected values
and first difference for different levels of one of my independent variables, I
get 50
Hello,
I want to place two plots on top of each other. However, the problem
is that I can't figure out a simple way to align them correctly. Is
there a way to specify this?
Since the data is bunch of coordinates and the second layer is an
outline of a map (a .ps file I import using the grImport pa
R 2.8.1
windows XP
I am getting an error message that I don't understand when I try to run GLM.
The error only occurs when I have all independent variables in the model. When
I drop one independent variable, the model runs fine. Can anyone help me
understand what the error means and how I can c
On Wed, 30 Dec 2009, John Sorkin wrote:
R 2.8.1
Rather old: have you updated package boot since?
windows XP
I am trying to learn how to use the boot function to perform a
bootstrap of a regression. I have written a short trial program,
shown below. Clearly I have done something wrong as t
I am having the same issue with the HDF5 package. I installed the
latest hdf5 DLLs from HDFGroup. I also installed the HDFView
application from the same. This was all done on Windows. The example
in ?hdf5load can be used to test. The example works fine for saving and
loading the structure,
Dear Clara,
could you, please, share the summary() of your data.
bests
milton
2009/12/30 Clara Brück
> Hi,
>
> I ran a negative binomial regression (NBR) using the Zelig-package and the
> negbin model.
> When I then try to use the simumlation approach using the setx () and sim()
> functions t
I forgot to cc: the list on this response.
-- Forwarded message --
From: Douglas Bates
Date: Wed, Dec 30, 2009 at 8:05 AM
Subject: Re: [R] glm error: cannot correct step size
To: John Sorkin
On Wed, Dec 30, 2009 at 7:50 AM, John Sorkin
wrote:
> R 2.8.1
> windows XP
> I am ge
I got the following after running succesfully through this loop 28 million
times... the loop opens text files in a directory and inserts line by line
into a database...
*** caught segfault ***
address 0xc010, cause 'memory not mapped'
Traceback:
1: .getGeneric(f, where, package)
2: getGene
Hi all,
Given the following,
> xx
[[1]]
V1 V2 V3
[1,] 1 2 3
[2,] 4 5 6
[3,] 7 8 9
[[2]]
V1 V2 V3
[1,]10 11 12
[2,]13 14 15
[3,]16 17 18
[[3]]
V1 V2 V3
[1,]19 20 21
[2,]22 23 24
[3,]25 26 27
how do i extract elements in each file so that after transpose, it looks
Hey R Users
I am trying to to implement a linux snow sockets parallelism in R, I am
pretty new to parallel computing
Here is the problem I am facing
Whenever I am doing
newSOCKnode("localhost") Its working fine
But whenever I do newSOCKnode("ip to another computer on the network ")
It throws
On 30/12/2009 9:20 AM, Nick Torenvliet wrote:
I got the following after running succesfully through this loop 28 million
times... the loop opens text files in a directory and inserts line by line
into a database...
This looks like a bug in RMySql or possibly R. What versions are you
using?
Thanks Duncan, I'll work on reproducibility and possibly getting a core
dump... If I get those I'll post to R-dev or RMySQL-dev.
Nick
On Wed, Dec 30, 2009 at 9:36 AM, Duncan Murdoch wrote:
> On 30/12/2009 9:20 AM, Nick Torenvliet wrote:
>
>> I got the following after running succesfully through
Hello,
I look for a simple command computing multivariate group means and
returning an object of class "matrix" rather than "list". Does any
such function exist in standard packages?
I'm beginning with R, so I'm sorry if the solution is trivial.
Ondra Mikula
___
Prof Ripley,
Thank you for your advise. You recommend I consult the "book for which
this is support software." I would be happy to do so, but I don't know
what book you are referring to.
Thank you,
John
John David Sorkin M.D., Ph.D.
Chief, Biostatistics and Informatics
University of Maryland
Perhaps this will give a clue:
rpois(1,-1)
[1] NaN
Warning message:
In rpois(1, -1) : NAs produced
# (lambda needs to be nonnegative)
-Peter Ehlers
Clara Brück wrote:
Hi,
I ran a negative binomial regression (NBR) using the Zelig-package and the
negbin model.
When I then try to use the sim
John,
packageDescription('boot')
will give you a hint.
-Peter Ehlers
John Sorkin wrote:
Prof Ripley,
Thank you for your advise. You recommend I consult the "book for which
this is support software." I would be happy to do so, but I don't know
what book you are referring to.
Thank you,
Joh
If I understand, you can try this:
array(do.call(rbind, xx), c(3, 3, 3))
On Wed, Dec 30, 2009 at 11:45 AM, Muhammad Rahiz
wrote:
> Hi all,
>
> Given the following,
>
>> xx
> [[1]]
> V1 V2 V3
> [1,] 1 2 3
> [2,] 4 5 6
> [3,] 7 8 9
> [[2]]
> V1 V2 V3
> [1,]10 11 12
> [2,]13 14 15
I've searched and tried several ideas (na.action. and other things), but I
can't see
to figure this out.
I'm guessing this is so simple I'll feel foolish for asking, but here goes.
Thanks,
L.A.
Dataset$Rcil=with(Dataset, ifelse(Rpr >= .95, Dataset[,"percentchgn"], NA))
Dataset$LLCI<-with(Datase
Dear All,
I have a matrix like X and need to create a new matrix based on the vector
m which gives the number of replicates for each unique row. The resulting
matrix should look like y.
> x
x1 x2
[1,] 2 0.5
[2,] 2 0.5
[3,] 2 0.5
[4,] 6 1.0
[5,] 6 1.0
[6,] 6 1.0
[7,] 1 1.5
[8,] 1 1.5
[9,] 1 1.
Dear kind list people:
I have the following code:
>hours
[1] "0" "1" "2" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13"
"14" "15"
[16] "16" "17" "18" "19" "20" "21" "22" "23"
> alist
$`0`
[1] 3 10 10 6 5 6 4 8 9 3 7 5 8 3 6 7 2 6 6 1 4 8
10 4 10
[26] 13 6 2 8 4 7
Hi,
I tried to be comprehensive but Jim's comment is indeed in place.
I have data of a practice experiment where people practice a certain motor
task and time-to-completion was recorded.
Appropriately, the time measure declines as practice goes on. And, again
appropriately, the relation seems to
Hi everyone,
Thanks a lot for the explanationâ¦
I tried the following code to compute R2 for a regression system but it does
not work:
my_svm_model <- function(myformula, mydata, mytestdata)
{
mymodel <- svm(myformula, data=mydata)
k<- summary(mymodel)
k$r.squared
}
Can anyone please
Try this:
Dataset$LLCI<-with(Dataset, ave(Rcil, LEAID, Property, FUN =
function(x)max(x, na.rm = TRUE)))
On Wed, Dec 30, 2009 at 2:44 PM, L.A. wrote:
>
>
> I've searched and tried several ideas (na.action. and other things), but I
> can't see
> to figure this out.
> I'm guessing this is so simpl
First of all your expression 'i*j' is storing on top of one another. Look
at what happens in the case of i=1,j=8 i=2,j=4 i=4,j=2, These are
all storing to the same location. Instead make 'mn' & 'li' matrices:
mn <- matrix(length(alist), 1000)
and then within the loop:
mn[i,j] <- value
Oops. Thank you. I guess I needed mn[i*1000 + j]. I should have known
better.
But I had wanted to make this into a data frame with
df=data.frame(mn, il)
so that I could plot it using factors. Can I do that with a matrix?
And can I eliminate the loops?
On 12/30/09 12:11 PM, jim holtman wrote:
> F
Try this:
unique(x)[rep(1:nrow(unique(x)), m),]
On Wed, Dec 30, 2009 at 2:35 PM, wrote:
> Dear All,
>
> I have a matrix like X and need to create a new matrix based on the vector
> m which gives the number of replicates for each unique row. The resulting
> matrix should look like y.
>
>> x
> x
Greetings:
I could also use guidance on this topic. I provide manure sample proficiency
sets to agricultural labs in the United States and Canada. There are about
65 labs in the program.
My data sets are much smaller and typically non-symmetrical with obvious
outliers. Usually, there are 30 to 6
Look at the subplot function in the TeachingDemos package, it may do what you
want.
--
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-project.org [mailto:r-help-boun...@r-
> pr
Sounds like you might want to use nls() to fit the data
and then use either curve() or predict() to do the
plotting.
-Peter Ehlers
Dror D Lev wrote:
Hi,
I tried to be comprehensive but Jim's comment is indeed in place.
I have data of a practice experiment where people practice a certain moto
Here is a hint as to how to replace the loops:
> hours <- 0:5
> result <- lapply(hours, function(.hr){
+ cbind(.hr, replicate(5, mean(sample(1:100, 1000, replace=TRUE
+ })
> do.call(rbind, result)
.hr
[1,] 0 50.232
[2,] 0 51.135
[3,] 0 49.169
[4,] 0 50.264
[5,] 0 52.62
Hi Nancy,
On Wed, Dec 30, 2009 at 12:08 PM, Nancy Adam wrote:
> Hi everyone,
> Thanks a lot for the explanation…
>
> I tried the following code to compute R2 for a regression system but it does
> not work:
>
> my_svm_model <- function(myformula, mydata, mytestdata)
> {
> mymodel <- svm(myformu
There is a function called defaultSummay in the caret package that
will compute r-squared and rmse.
Max
On Dec 30, 2009, at 1:30 PM, Steve Lianoglou > wrote:
Hi Nancy,
On Wed, Dec 30, 2009 at 12:08 PM, Nancy Adam
wrote:
Hi everyone,
Thanks a lot for the explanation…
I tried the f
Gents:
Whole books could be -- and have been -- written on this matter. Personally,
when scientists start asking me about criteria for "outlier" removal, it
sends shivers up my spine and I break into a cold, clammy sweat. What is an
"outlier" anyway?
Statisticians (of which I'm one) have promulga
It worked perfectly. Thank you!
On Wed, Dec 30, 2009 at 12:21 PM, Henrique Dallazuanna wrote:
> Try this:
>
> unique(x)[rep(1:nrow(unique(x)), m),]
>
>
> On Wed, Dec 30, 2009 at 2:35 PM, wrote:
> > Dear All,
> >
> > I have a matrix like X and need to create a new matrix based on the
> vector
>
Thank you Peter.
nls() & predict() seems to do the job.
dror
-
On Wed, Dec 30, 2009 at 8:10 PM, Peter Ehlers wrote:
> Sounds like you might want to use nls() to fit the data
> and then use either curve() or predict() to do the
> plotting.
>
> -Peter Ehlers
>
> Dror D Le
How for the love of god can I prevent the lm() function from padding on to
my factor variables?
I start out with 2 tables:
Table1
123123
124351
...
626773
Table2
Count,IS_DEAD,IS_BURNING
1231,T,F
4521,F,T
...
3321,T,T
Everything looks fine when I import the data.
then we get a
oh_crap <- lm(t
I'm wondering if anyone knows of a way to capture system messages, for
instance when I do the following:
> system("../DBScripts/getEODData.sh")
.//LSE_20091230.txt: 154.80 kB 207.24
kB/s
./Fundamentals//LSE.txt: 420.58 kB 301.47
kB/
Nick,
You don't specify OS, so details might differ, but on my linux system the
help for system (which should be the first place you'd look anyway) has
an entire section on stdout and stderr
Stdout and stderr:
Error messages written to ‘stderr’ will be sent by the shell to
the terminal
?capture.output
?sink
What is the problem you are trying to solve?
Sent from my iPhone.
On Dec 30, 2009, at 15:15, Nick Torenvliet
wrote:
I'm wondering if anyone knows of a way to capture system messages, for
instance when I do the following:
system("../DBScripts/getEODData.sh")
.//LSE_
Gee, so much excitement over such a little thing.
So how exactly would you prefer lm() to tell you
what levels of your factors are being taken as the
reference levels?
Post-processing, if necessary, would seem to be
pretty trivial.
If you want to re-run lm() on modified sets of
predictors, what'
Hi:
An alternative is the following:
# This regenerates your dataset:
xx <- list(matrix(1:9, nrow = 3, byrow = TRUE),
matrix(10:18, nrow = 3, byrow = TRUE),
matrix(19:27, nrow = 3, byrow = TRUE))
# Flatten matrix elements of each component into vectors:
xxf <- lapply(xx,
Hello
I run a factorial analysis on 20 variables describing the behaviour of
insects on 9 different resistant plants. I then biologically interpreted
each of the 5 factors obtained, with respect to the variables with the
highest loading value for each factor. And I run a GLM on each factor with
p
Dear Clara,
Thanks for the reply. I am forwarding your message to the list, ok.
When I wrote was a way of get further information to help the helpers.
happy holidays,
milton
-- Forwarded message --
From: Clara Brück
Date: 2009/12/30
Subject: Re: [R] Negbin Error Warnings
To: mi
On 12/30/2009 08:32 PM, Jay wrote:
Hello,
I want to place two plots on top of each other. However, the problem
is that I can't figure out a simple way to align them correctly. Is
there a way to specify this?
Since the data is bunch of coordinates and the second layer is an
outline of a map (a .p
I just upgraded to R version 2.10.1 Patched (2009-12-27 r50842) on WinXP,
and I'm getting this error inconsistently both on start and close of
sessions. I never saw it on previous versions (from 2.6 to 2.9). Not sure
what to check on, I don't believe I'm using any more resources than I
normally
To Experts,
x = x1 + x3
y = x2 + x3
x3 = cov(x1,x2)
By refer to package "bivpois", I'ld like to downweight previous x,y in my
data based on date, I am wondering if lambda3 should robust as well, since
lambda3 measure the co-relationship of lambda1 and lambda2, but if robust
lambda3 might effect
Clara,
The most likely problem is that theta==0 for some of the
calculations. Or mu is NA, I suppose.
-Peter Ehlers
milton ruser wrote:
Dear Clara,
Thanks for the reply. I am forwarding your message to the list, ok.
When I wrote was a way of get further information to help the helpers.
happ
peter_kel...@fws.gov wrote:
I just upgraded to R version 2.10.1 Patched (2009-12-27 r50842) on WinXP,
and I'm getting this error inconsistently both on start and close of
sessions. I never saw it on previous versions (from 2.6 to 2.9). Not sure
what to check on, I don't believe I'm using any
Hi,
I'm pretty much an R noob and I'm missing some paradigm in R I think.
I can't figure our how to compare numerics. here's a transcript of my
tests. Any pointers?
> print(range_sd)
[1] 34.40783
> is.numeric(range_sd)
[1] TRUE
> is.numeric(foo)
[1] TRUE
> is.double(range_sd)
[1] TRUE
>
On 12/31/2009 02:41 PM, donahc...@me.com wrote:
Hi,
I'm pretty much an R noob and I'm missing some paradigm in R I think.
I can't figure our how to compare numerics. here's a transcript of my
tests. Any pointers?
Hi donahchoo,
You're comparing the printed value of range_sd, which has been
On Dec 30, 2009, at 10:10 PM, Jim Lemon wrote:
On 12/31/2009 02:41 PM, donahc...@me.com wrote:
Hi,
I'm pretty much an R noob and I'm missing some paradigm in R I
think. I can't figure our how to compare numerics. here's a
transcript of my tests. Any pointers?
Hi donahchoo,
You're comp
Dear,
I wanna make cross-validation for the species data of species distribution
models.
Please kindly suggest any package containing cross validation suiting the
purpose.
Thank you.
Elaine
[[alternative HTML version deleted]]
__
R-help@r-pro
donahc...@me.com wrote:
On Dec 30, 2009, at 10:10 PM, Jim Lemon wrote:
On 12/31/2009 02:41 PM, donahc...@me.com wrote:
Hi,
I'm pretty much an R noob and I'm missing some paradigm in R I
think. I can't figure our how to compare numerics. here's a
transcript of my tests. Any pointers?
H
59 matches
Mail list logo