mean.
>
> The suggestion to use ordinary regression on the observed times is
> wrong. Censored data is more complex than that.
>
> Terry Therneau
>
> __
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo
t; 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, self-contained, reproducible code.
>
--
*James C. Whanger
Research Consultant
2 Wolf
We would like to call R functions from within MS SQL Server queries. Any
advice on this would be appreciated.
Thanks!
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-proje
Hi, does anyone know if there is a way to easily extract p-values from the
regsubsets() function?
Thanks,
James Stegen
p.s. this is a reposting due to me not putting in a useful subject heading...
--
James C. Stegen
NSF Postdoctoral Fellow in Bioinformatics
University of North Carolina
Chapel
Hi, does anyone know if there is a way to extract the variance of each
variable explained in a structural equation model when using the sem()
function?
Thanks,
James Stegen
--
James C. Stegen
NSF Postdoctoral Fellow in Bioinformatics
University of North Carolina
Chapel Hill, NC
919-962-8795
Hi, does anyone know if there is a way to easily extract p-values from
the regsubsets() function?
Thanks,
James Stegen
--
James C. Stegen
NSF Postdoctoral Fellow in Bioinformatics
University of North Carolina
Chapel Hill, NC
919-962-8795
ste...@email.unc.edu
http://www.unc.edu/~stegen
Is it possible to send data from an executing R script, to external R script
files, on linux in this case, get that external R script to execute, and pass
results back to the central script? If so what commands should I be looking
at? I've googled for R and external, stuff like that but no luc
Could anyone give me some clues as to the best way to debug this error message?
I think it is from the passing of variables back to R from the jags function
which does Bayesian fitting. The curious part for me is that the error
messages seem random, yet the input data are always the same. An
Here's an example of a PDF with the tails shaded:
http://stackoverflow.com/q/3494593/37751
-JD
On Mon, Nov 8, 2010 at 10:18 AM, Wu Gong wrote:
>
> I want to create a graph to express the idea of the area under a pdf curve,
> like
>
> http://r.789695.n4.nabble.com/file/n3032194/w7295e04.jpg
>
>
The following output results from fitting models using lmer and lm to
data arising from a split-plot experiment (#320 from "Small Data Sets"
by Hand et al. 1994). The data is given at the bottom of this message.
My question is why is the sum of squares for variety (V) different in
the ANOVA t
In polr.R the (several) functions gmin and fmin contain the code
> theta <- beta[pc + 1L:q]
> gamm <- c(-100, cumsum(c(theta[1L], exp(theta[-1L]))), 100)
That's bad. There's no reason to suppose beta[pc+1L] is larger than
-100 or that the cumulative sum is smaller than 100. For pr
tions
such as sort().
-Original Message-
From: David Winsemius [mailto:dwinsem...@comcast.net]
Sent: Sunday, October 31, 2010 12:24 PM
To: James Hirschorn
Cc: R-help@r-project.org
Subject: Re: [R] extracting named vector from dataframe
On Oct 31, 2010, at 11:54 AM, James Hirschorn
Suppose df is a dataframe with one named row of numeric observations. I want
to coerce df into a named vector.
as.vector does not work as I expected: as.vector(df) returns the original
dataframe, while as.vector(df,mode="numeric") returns an unnamed vector of
NAs.
This works:
> v <- as
>
> Here is a dodge I often use. This is a mock-up example.
Very instructive (and helpful) ...
>
> ___
>
> bar <- data.frame(matrix(rnorm(1001), nrow = 1))
> names(bar)[1] <- "y" ## say
> head(bar[,1:5])
>
> nbar <- names(bar)
> form <- as.formula(paste(nbar[1], "~", paste(nbar[-1],
What is a good way to enter a very long model formula. For example:
y ~ Input.2 + Input.3 + ... + Input.1000
(assuming the corresponding dataframe has many other columns).
Is there a way to convert a character string to a formula? Are there command
line expansions in R besides the simple '.'?
els(ind) : NAs produced by integer overflow
3: In grp * nlevels(ind) : NAs produced by integer overflow
4: In grp * nlevels(ind) : NAs produced by integer overflow
I tried searching for this error message but didn't find anything. I have
very little programming background, but my colleague re
I'm using the following model to do an analysis
faicout <- glm(cbind(events,patnums-events) ~ as.factor(treat) +
as.factor(numtrial), family = binomial )
Is this example there are 4 treatments . In the glm object I can find the
contrasts of the main treats vs the first i.e. 2v1, 3v1 and 4v1 .
I can not understand why this fails
>
> faicoutput2 <- list(stuff21 = as.numeric(faicout$coefficients[2]),
+ stuff31=as.numeric(faicout$coefficients[3]),
+ stuff41=as.numeric(faicout$coefficients[4]),
+ stuff32=(stuff21-stuff31),
+
Do I recall correctly that there is an R package that can take an image,
and help one estimate the x/y coordinates? I can't find the package,
thought it was an R-tool, but would appreciate any leads.
Thanks,
Rob
__
R-help@r-project.org mailing list
Sorry for the verbose example. I want to row bind two matrices, and all works
except I want the column labelled "row" to be sequential in the new matrix,
shown as "mat3" here, i.e. needs to be 1:6 and not 1:3 repeated twice. Any
suggestions?
Thanks
J
> colnm1 <- c("row","ti","counti")
> col
I've tried hard to find a way to exponentiate each element of a whole matrix
such that if I start with A
A = [ 2 3
2 4]
I can get back B
B = [ 7.38 20.08
7.38 54.60]
I've tried
B <- exp(A) but no luck.
Thanks
J
===
Dr. Jim Maas
University of
I'm attempting to learn how to use the debug function to find the values of
some variables. I've found a couple of documents describing the basics and
they show examples that the debugger returns
"Browse[1]>"
but for some reason when I follow the examples I get
"Browse[2]>"
What is the "2"
d columns
differently, analogously to write.table. However, there does not even seem to
be
an option to make read.table behave analogously.
- Original Message ----
From: peter dalgaard
To: james hirschorn
Cc: r-help@r-project.org
Sent: Tue, October 5, 2010 7:25:52 AM
Subject: Re: [R
Hi Thomas,
Thanks for the reply.
1. In the first pick, I draw 'A' genes from N, without replacement.
2. Similarly, in the second pick, I draw 'B' genes from N, without replacement
(and 'C' genes from 'N' etc.)
3. Order does not matter - so the two cases you cited are equivalent.
I would like to
Suppose I have a data file (possibly with a huge number of columns), where the
columns with factors are coded as "1", "2", "3", etc ... The default behavior
of
read.table is to convert these columns to integer vectors.
Is there a way to get read.table to recognize that columns of quoted number
Hi All,
My apologies if this is a totally newbie question.
I want to calculate the probability that a particular set of genes is picked
repeatedly for 3 samplings. For example, if from a total of 'N' genes, I pick
'A' number of genes in the first pick, 'B' number of genes in the second pick,
This code worked fine for me, then did some cleaning up of formatting using ESS
(Emacs) and now I get this error, no idea what is causing it, all the
brackets/parentheses seem to be balanced. What have I done wrong?
Thanks
Jim
p0.trial01 <- 0.25
TruOR01 <- 0.80
num.patients.01 <- 50
num.tri
Dr. Jim Maas
University of East Anglia
From: Michael Bedward [michael.bedw...@gmail.com]
Sent: 18 September 2010 04:14
To: Maas James Dr (MED)
Cc: r-help@r-project.org
Subject: Re: [R] removing specific rows from array
Here's one way...
treats <- c(&
I'm attempting to create an array of treatment comparisons for modelling data
generation. This involves comparison of one treatment (c2) with another (c3),
relative to a common comparator (c1).
Attached code gives me the correct array but need to remove duplicates.
Duplicates relate only to c
Simple one here ... but can't get it to work ...
for (i in 1:4){
paste("stuff",[i]),sep="") <- 3 + i
}
ls()
rm(list=ls())
I just want it to create 4 new variables called stuff1, stuff2, stuff3, stuff4
with the corresponding assignments. I realise that there are more elegant
functions bu
Hi,
I was trying to install R in my home directory on a Mac OS X Server running
Darwin. How do I go about installing it? How can I install from the binary
provided (R-2.11.1.pkg) from command line?
Is there any other information that I can provide?
thanks
[[alternative HTML ve
Hi,
I looked at the help documentation, but couldn't find the algorithm for
calculating the modified jaccard index for separate sets of biclusters. Is
there
a link to some documentation on this?
many thanks!
[[alternative HTML version deleted]]
__
Hello,
I am currently using the polar.plot function in the plotrix package to graph
data. Unfortunately, it seems that the default for the labels is to have a
background color that is covering the line representing my data, making it
difficult to read. Is there a way to make this label backgrou
Thank you Marc - the first scenario.
On Mon, Sep 13, 2010 at 2:04 PM, Marc Schwartz wrote:
>
> On Sep 13, 2010, at 10:30 AM, James Hudson wrote:
>
> > Iâd like to sample the vector âyâ° repeatedly. In this dummy dataset,
> > Iâd
> > like to sample (and
Id like to sample the vector y repeatedly. In this dummy dataset, Id
like to sample (and store) it 1, 2, and 3 times.
Is there a straightforward way to do this without using a for loop?
x <- c(1 :3)
y <- c(1:10)
(run.sample <- sample (y, x))
Thanks very much,
Jam
Hi Peng, Gabor & Peter,
Thank you very much for replying me so soon. I will try it right now!
--
View this message in context:
http://r.789695.n4.nabble.com/How-to-project-a-vector-on-a-subspace-tp2530886p2532388.html
Sent from the R help mailing list archive at Nabble.com.
_
I am looking for the syntax to capture XML tags marked with
/DescriptorName MajorTopicYN="Y"/ , but the combination of the internal
space (between "Name" and "Major" and the embedded quote marks are
defeating me. I can get all the "DescriptorName" tags, but these include
both MajroTopicYN
Hi experts,
I have a subspace represented as matrix of basic vectors and I want to
project a vector on that subspace. Does R have any function that help me to
do so?
Thanks,
James.
--
View this message in context:
http://r.789695.n4.nabble.com/How-to-project-a-vector-on-a-subspace
() but I don't know how to bring the result of
kcca() to use as parameters for gausspr().
Any replies is appreciated!
Thanks a lot,
James.
--
View this message in context:
http://r.789695.n4.nabble.com/How-to-use-prediction-tp2527030p2527030.html
Sent from the R help mailing list archi
__
From: Ben Bolker
To: r-h...@stat.math.ethz.ch
Sent: Thu, September 2, 2010 2:06:47 PM
Subject: Re: [R] Linear models (lme4) - basic question
James Nead yahoo.com> writes:
>
> Sorry, forgot to mention that the processed data will be used as input for a
> classification alg
Sorry, forgot to mention that the processed data will be used as input for a
classification algorithm. So, I need to adjust for known effects before I can
use the data.
thanks
From: Bert Gunter
Cc: r-help@r-project.org
Sent: Thu, September 2, 2010 12:46:13
Hi Bert,
Thanks for the reply.
Height, was just as an example. Perhaps, I should have said 'x' instead of
height.
Essentially, what I want to do is adjust the data for known effects. After I've
done this, I can conduct further analysis on the data (for example, if another
variable 'z' has an
Hi,
Sorry for a basic questions on linear models.
I am trying to adjust raw data for both fixed and mixed effects. The data that
I
output should account for these effects, so that I can use the adjusted data
for
further analysis.
For example, if I have the blood sugar levels for 30 patients,
Hi,
I wanted to compare the quality of biclusters obtained from the various
biclustering algorithms. Is there a function/metric in biclust (or some other
package) that will enable me to do this?
thanks!
[[alternative HTML version deleted]]
If possible I would like to combine two different character arrays in
combinations
Array1 <- c("height","weight","age","sex")
Array2 <- c("trt0","trt1","trt2")
I would like to combine these two character vectors to end up with such ...
Array3
"height.trt0.trt1"
"height.trt0.trt2"
"weight.trt0
Simple one, have read and googled, still no luck!
I want to create several empty vectors all of the same length.
I would like multiple empty vectors (vec1, vec2, vec3) and want to create them
all in one line.
I've tried
vec1,vec2,vec3 <- vector(length=5)
and
c(vec1,vec2,vec3) <- vector(length=
Is it possible to get R to output the value of an expression, that is being
calculated within a function? I've attached a very simple example but for more
complicated ones would like to be able to debug by seeing what the value of
specific expressions are each time it cycles through a loop that
e this out!
Much appreciated
James
-Original Message-
From: Steve Lianoglou [mailto:mailinglist.honey...@gmail.com]
Sent: Thursday, August 19, 2010 11:39 AM
To: Watling,James I
Cc: r-h...@lists.r-project.org
Subject: Re: [R] probabilities from predict.svm
On Thu, Aug 19, 2010 a
svm.model, predict.data,
probability=T)should be so off-base, but it seems like they are.
Any thoughts?
James
-Original Message-
From: Steve Lianoglou [mailto:mailinglist.honey...@gmail.com]
Sent: Thursday, August 19, 2010 10:24 AM
To: Watling,James I
Cc: r-h...@lists.r-proj
I would appreciate any suggestions on which function to use to write subsequent
functions analysing combinations of treatments.
This refers to experimental trials of medical treatments. I want to write
routines to analyse various comparisons (combinations)
So if 5 treatments are available
1) How does one capture the plots from the plsmo procedure? Simply
inserting a routing call to a graphical device (such as jpeg, png, etc)
and then running the plsmo procedure (and then dev.off()) does not route
the output to the file system. 1b) Related to above, has anyone thought
of revising
On Aug 15, 2010, at 10:40 AM, Gabor Grothendieck wrote:
> On Sun, Aug 15, 2010 at 12:21 PM, James Toll wrote:
>> Hi,
>>
>> I am trying to add a rectangular colored background area to a plot of a time
>> series of relative price changes. I believe that what I'm
xamples linked above?
I'd like to be able to use this with chartSeries, rather than plot, but I
thought it would be easiest to figure it out using plot first. Clearly that
hasn't helped me.
Thanks for any advice you can provide.
James
__
R
I am encountering an error I do not know how to debug. The error arises
when I try to add an interaction term involving two continuous
variables (defined using rcs functions) to an existing (and working) model.
The new model reads:
model5 <- lrm( B_fainting ~ gender+ rcs(exactage, 7) +
Dear All,
I have come across a very surprising result as I have started to learn how
to use R to pull data from the web for analysis.
I am trying to isolate that table headers for the quarterly income
statement (qtrinc) that I pulled from Google finance. I executed the
following commands after i
Dear All,
I have imported an HTML document to R (called tables) and wish to select
certain pieces of it for processing. The first few lines of the object
appear as follows:
> tables
[[1]]
In Millions of USD (except for per share items)
3 months ending 2010-06-30
3 months ending 2010
tk/libs/i386/tcltk.so
Reason: image not found
Error: package/namespace load failed for 'tcltk'
Cheers,
James
On 17 Jul 2010, at 18:12, Peter Ehlers wrote:
On 2010-07-17 9:50, James Platt wrote:
The other question I have:
Is there any way to link the data point on the graph to t
The other question I have:
Is there any way to link the data point on the graph to the name of a
row
i.e in my table:
name value_1 value_2
bill 14
ben 2 2
jane 3 1
I click on the data point at 2,2 and it would read out ben
thanks again.
James
ue_1"]
y <- test[ , "value_2"]
#plot
plot(x, y)
cheers,
James
On 17 Jul 2010, at 16:07, Joshua Wiley wrote:
Hi James,
I believe the issue has to do with the values you assigned to 'x' and
'y'. You call the function c() on seq["value_1"], but you
, header=TRUE)
>x <-c(seq["value_1"])
>y <-c(seq["value_2"])
>plot(x,y)
and i get this error
Error in xy.coords(x, y, xlabel, ylabel, log) :
(list) object cannot be coerced to type 'double'
What does this mean and how do i fix it?
Thanks for t
#x27;m definitely going to try this, thanks in advanced! I'm excited,
maybe I'll finally get passed this hurdle. :)
-James
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting gu
On Thu, Jul 15, 2010 at 8:43 PM, Erik Iverson wrote:
> On 07/15/2010 07:10 PM, James wrote:
>> I'm completely new to R, and I'd like to do something like this:
>> > x=c(1,2,3)
>> > plot(x,x)
>> At this point, R creates a file "Rplots.
love to be able to set
the default name for output images.
-James
[[alternative HTML version deleted]]
__
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/postin
I'm completely new to R, and I'd like to do something like this:
> x=c(1,2,3)
> plot(x,x)
At this point, R creates a file "Rplots.pdf", since the default device is
PDF and the default filename is "Rplots.pdf". I know I can set the default
device like this:
> options(device="png")
B
Relative noob here, I have a data.frame and simply want to add an explicit
column of names in column 1 of the form
"trial_number01" for row 1, "trial_number02" for row 2 etc. It is simply
for visual purposes and to explain data to others. I've tried
Using row.names and other but still no l
e.
__
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, self-contained, reproducible code.
_____
d to
allow one to query any DBMS. Since RMySQL is MySQL-specific, it may be
more efficient. Anyway, why don't you just try it and see?
Best,
Jim
Best,
Ralf
On Wed, Jun 23, 2010 at 4:36 PM, James W. MacDonald
wrote:
Hi Ralf,
Ralf B wrote:
I am running a simple SQL SELECT statemen
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, self-contained, reproducible code.
--
James W. MacDonald, M.S.
Biostatistician
Douglas Lab
University of Mich
s
#like from time 10 to time 24 and time 51 to time 86
starts <- c(10,51)
ends <- c(24,86)
results <-c(NA,NA)
#then you'd typically loop
for (i in 1:2) { results[i] <- mean(d[starts[i]:ends[i]) }
can it be done without looping?
Thanks in advance.
James
(when you don't specify, it chooses the units according to some rules)
>
> -Don
>
> At 4:24 PM -0400 6/14/10, James Rome wrote:
>> I have two dataframe columns of POXIXct data/times that include seconds.
>> I got them into this format using for example
>> zsort$ETA &
I have two dataframe columns of POXIXct data/times that include seconds.
I got them into this format using for example
zsort$ETA <- as.POSIXct(as.character(zsort$ETA), format="%m/%d/%Y %H:%M:%S")
My problem is that when I subtract the two columns, sometimes the
difference is given in seconds, and
ne: 3371-4346
__
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, self-contained, reproducible code.
--
James W
You may want to try read.delim if you are having troubles with
read.table.
Jim
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]
On Behalf Of dhanush
Sent: Thursday, June 03, 2010 4:33 AM
To: r-help@r-project.org
Subject: [R] import text file int
Dear R- User,
I have a dataset that looks like the following:
jh<-data.frame(
'id'=seq(1,10,1),
'time0'=c(8,5,8,8,9,NA,NA,2,4,5),
'time4'=c(NA,NA,9,8,NA,2,3,2,4,5),
'time8'=c(NA,2,8,NA,5,NA,2,3,NA,4),
'time12'=c(NA,2,NA,NA,NA,3,3,2,3,NA),
'sex'=c('m','f','m','m','f','f','f','m','f','m'
in dataframe 'dat' such that the
dropout time is the time to drop out by the subject as follows:
dat<-data.frame(
'id'=rep(c(1,2,3),each=3),
'time'=rep(c(1,2,3),3),
'y'= c(2,2,NA,2,NA,NA,2,5,7),
'dropout time'=
Dear R-users, I have a problem, I have the following dataframe:
d<-data.frame(
'y1'=c(1,2,1,2,1,NA,NA),
'y2'=c(1,2,1,1,1,2,1),
'y3'=c(1,NA,1,NA,NA,2,1),
'y4'=c(NA,2,NA,1,1,2,NA),
'a'=c(1,1,1,1,1,1,2)
)
where the last variable counts the number of missing values in a row. Now, i
want to set ro
Dear R- users,
Pls help me with the following problem. I have a dataset that loooks like the
following:
jh<-data.frame(
'id'=seq(1,10,1),
'time0'=c(8,5,8,8,9,NA,NA,2,4,5),
'time4'=c(NA,NA,9,8,NA,2,3,2,4,5),
'time8'=c(NA,2,8,NA,5,NA,2,3,NA,4),
'sex'=c('m','f','m','m','f','f','f','m','f','m'
2)),data = battery.df)
dummy.coef(battery.fit)
Error in rep.int(xl[[i]][1L], nl) : invalid 'times' value
Thanks,
James
--
James M. Curran, Ph.D.
Associate Professor
Director Bioinformatics Institute
Department of Statistics
Faculty of Science
Private Bag 92019
Auckland
New Zealand
___
Subsequent investigations (via GIMP) show that the problem is in OO, and
now with the images themselves.
Off to the OO forums.
Original Message
Subject:Fidelity of lattice graphics captured to jpeg or png
Date: Thu, 29 Apr 2010 08:05:04 -0700
From: Rob James
To
I am generating images via lattice from Frank Harrell's RMS package.
These images are characterized by coloured lines and grey-scale
confidence intervals. I need to port them to Openoffice/etc, and have
tried both png and jpeg (at high quality), but in neither format can I
subsequently see the
What causes the error report:
logical(0)
to arise in the rms function lrm?
Here's my data:
But both the dependent and the independent variable seem fine...
> str(AABB)
'data.frame':1176425 obs. of 9 variables:
$ sex : int 1 1 0 1 1 0 0 0 0 0 ...
$ faint : int 0 0 0 0 0 0 0 0 0 0
sed: an active and
mostly friendly R community. In addition there is a plethora of R
community groups, London, Chicago, New York come to mind - drop along to
some of them. And start to use R.
Regards
John James
Mango
- Original Message -
From: r-help-boun...@r-project.org
To: r-
The data are at http://dl.dropbox.com/u/537118/gdf.zip
On 4/17/2010 1:42 AM, Deepayan Sarkar wrote:
On Fri, Apr 16, 2010 at 1:54 PM, James Rome wrote:
> Dear R-Help,
>
> With the attached data set, I am still getting incorrect bwplots
>
None of your attachments came through
On 4/16/2010 8:27 PM, Jun Shen wrote:Jim,
Try this,
bwplot(tt~as.factor(OnHour),data=gdf,..)
Jun Shen from Millipore
I already tried using a factor, and the data set I enclosed had
gdf$OnHFact which was already a factor. It gave the same wrong plot.
What did work was to call xyplot instead
Dear R-Help,
With the attached data set, I am still getting incorrect bwplots
> xyplot(gdf$tt~gdf$OnHour |gdf$Runway, data=gdf) # Is correct
> bwplot(gdf$tt~gdf$OnHour |gdf$Runway, data=gdf, horizontal=FALSE) #
Puts the boxes on the wrong x-axis values
# look especially at 0 and 3. How do
Alas, no one answered my last post about my problem of doing bwplot.
I think my problem is related to the fact that there is a value missing
in my data:
levels(as.factor(gdf$OnHour))
[1] "0" "1" "2" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13"
"14" "15"
[16] "16" "17" "18" "19" "20" "21
Best,
Jim
Thanks
Christoph
__
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, self-contained, reproducible c
Hi Vava,
What version of R are you using? I'm not sure but I think that R will
refuse to install a package in this way if the version of gplots is
incompatiable with the version of R you're using. You can check the
depends of packages on CRAN.
Regards,
James
Vava wrote:
Thank
Dear List,
I am having problems getting my box and whisker plots to put boxes on
the right x-axis values.
x is the hour of the day from 0 to 23.
> unique(mdf$OnHour)
[1] 5 4 6 7 11 12 9 8 19 14 13 21 20 10 18 17 15 16 23 22 0 1 3 2
mdf$OnHFact = factor(mdf$OnHour, levels=seq(0,23),
labe
Hi List,
Running R 2.10.1 on a fresh install of Windows 7. I get the following
error when loading the RPostgreSQL package.
>library(RPostgreSQL)
Loading required package: DBI
Error in inDL(x, as.logical(local), as.logical(now), ...) :
unable to load shared library
'C:/Users/james/D
I would like to make a series of bwplots with scales that are the same
on each plot. x is hours of the day, so I chose
hrs = seq(0, 24, 4)
hrlabs = c("0","4","8","12","16","20","")
g = bwplot((gdf$tt)~gdf$OnHour | gdf$Runway, data=gdf,
ylab="Taxi time (min
o do this
d = data.frame(x=c(1,1,2,4),y=c(10,11,12,13),z=c(20,19,18,17))
d.ordered = d[order(-d$y),]
aggregate(d.ordered,by=list(key=d.ordered$x),FUN=function(x){x[1]})
I've tried to use split and unsplit, but unsplit complained about duplicate
row names when reassembling the sub frames.
I am trying to calculate quantiles of a data frame column split up by
two factors:
# Calculate the quantiles
quarts = tapply(gdf$tt, list(gdf$Runway, gdf$OnHour), FUN=quantile,
na.rm = TRUE)
This does not work:
> quarts
04L 04R 15R 22L 22R 2732
33L
The key was to use grid.text() inside the panel function. It allows you
to specify things in 0-1 "npc" units.
On 4/1/10 12:23 PM, David Winsemius wrote:
>
> On Apr 1, 2010, at 11:53 AM, James Rome wrote:
>
>> I am drawing a density histogram, and want to label the plo
I am drawing a density histogram, and want to label the plots with the
mean using ltext(). But I need the x,y coordinates to feed into ltext,
and I can't calculate them easily from my data. Is there a way to get
the x and y ranges being used for the plot, so I can put the text at the
correct positi
On 3/31/2010 10:01 PM, Berwin A Turlach wrote:
G'day James,
On Wed, 31 Mar 2010 21:44:31 -0400
James Rome wrote:
> I need to make a bunch of PDF files of histograms.
>
[...]
> What am I doing wrong?
>
http://cran.ms.unimelb.edu.au/doc/FAQ/R-FAQ.html#Why-do-lattice_002
On 3/31/2010 10:01 PM, Berwin A Turlach wrote:
G'day James,
On Wed, 31 Mar 2010 21:44:31 -0400
James Rome wrote:
> I need to make a bunch of PDF files of histograms.
>
[...]
> What am I doing wrong?
>
http://cran.ms.unimelb.edu.au/doc/FAQ/R-FAQ.html#Why-do-lattice_002
I need to make a bunch of PDF files of histograms. I tried
gatelist = unique(mdf$ArrivalGate)
for( gate in gatelist) {
outfile = paste("../", airport, "/", airport, "taxiHistogram", gate,
".pdf", sep="")
pdf(file = outfile, width = 10, height=8, par(lwd=1))
title=paste("Taxi tim
I have data that is collected in two different time zones
z$OnDateTime <- as.POSIXct(runway$OnDateTime, tz = "EST5EDT",
format="%m/%d/%Y %H:%M")
is in Eastern time, and
zi$ActualOnLocal <- as.POSIXct(oooi$ActualOnLocal, tz="MST7MDT",
format="%m/%d/%Y %H:%M")
is in Mountain".
I converted the runway
In general, one should be able to turn off the legend entirely.
I did a plot with geom_jitter() and then overlaid it with geom_boxplot() and
I got a legend
with a sort of box drawn in a legend that was meaningless since there was no
factor involved.
Jim
--
View this message in context:
http://n
301 - 400 of 638 matches
Mail list logo