On Fri, Jan 2, 2009 at 3:20 AM, gallon li wrote:
> I have the following data
>
> ID x y time
> 1 10 20 0
> 1 10 30 1
> 1 10 40 2
> 2 12 23 0
> 2 12 25 1
> 2 12 28 2
> 2 12 38 3
> 3 5 10 0
> 3 5 15 2
> .
>
> x is time invariant, ID is the subject id number, y is changing over time.
>
> I want
t; legend. Thanks!
>
> On Wed, Sep 24, 2008 at 8:03 PM, hadley wickham wrote:
>> On Wed, Sep 24, 2008 at 7:57 PM, wrote:
>>>
>>>
>>> I have a more complicated function I am trying to write, but I run in to a
>>> problem when I want to
>&g
> naturally
> divided into pieces: the elements of the list. For this reason, the l*ply
> functions don't
> need an argument that describes how to break up the data structure.
>
> (from: plyr: divide and conquer, Hadley Wickham 2008)
>
> Perhaps a new case to conside
Or even more simply:
On Mon, Dec 29, 2008 at 12:17 PM, Henrique Dallazuanna wrote:
> Try this:
>
> do.call(rbind, lapply(l, "[", unique(unlist(sapply(l, names)
>
> Where "l" is your list.
Or even more simply:
library(plyr)
do.call(rbind.fill, l)
which doesn't get the variable order quite r
Hi Felipe,
It sounds like ForkLength is a factor - what deos str(FL) tell you?
You might also need geom_bar(..., stat = "identity") since your data
are pretabulated.
Hadley
On Fri, Dec 26, 2008 at 2:44 PM, Felipe Carrillo
wrote:
> Wayne:
> What's crowded are my x axis labels. The bars look fine
Hi Mike,
Yup, that's a bug that will be fixed in the next version. In the
meantime one easy fix is to add an \n on the end of the title string.
Hadley
On Tue, Dec 23, 2008 at 7:02 PM, Mike Lawrence wrote:
> On my machine (Mac OS 10.5.6, R 2.8.1) the following plot is drawn such that
> a substa
On Mon, Dec 22, 2008 at 7:15 PM, Ranney, Steven
wrote:
> Thank you all for your help. I appreciate the assistance. I'm thinking I
> should have been more specific in my original question.
>
> Unless I'm mistaken, all of the suggestions so far have been for maximum vol
> and maximum Length by La
On Mon, Dec 22, 2008 at 3:51 PM, Ranney, Steven
wrote:
> All -
>
> I have data that looks like
>
> psd Species Lake Length WeightSt.weightWr
> Wr.1 vol
> 432 substock SMB Clear150 41.00 0.01 95.12438
> 95.10118 0.0105
> 433 substock SMB Clea
Hi Erich,
Can you explain why you don't want them? The philosophy behind the
legend code is to attempt to match the appearance of the geoms in the
plot as closely as possible. There are a few exceptions, like this
diagonal line, where the legends are slightly different to make it
easier to see c
On Tue, Dec 16, 2008 at 5:40 PM, Prof Brian Ripley
wrote:
> On Tue, 16 Dec 2008, hadley wickham wrote:
>
>> Hi all,
>>
>> Is it possible to programmatically minimise the main window of the
>> windows R gui? I'm designing a small gui with gwidgets & RGtk2 fo
Hi all,
Is it possible to programmatically minimise the main window of the
windows R gui? I'm designing a small gui with gwidgets & RGtk2 for an
non-statistician to use, and it would be nice if I could easily hide
all the R stuff that they don't need.
Thanks,
Hadley
--
http://had.co.nz/
On Sun, Dec 14, 2008 at 6:18 PM, Dennis Fisher wrote:
> Colleagues,
>
> I am interesting in opening a PDF document via the command line from both
> Windows, OS X, and Linux ( R version 2.8.0). I found a command openPDF in
> Biobase. However, I would rather execute the command myself. For exampl
ggplot2
ggplot2 is a plotting system for R, based on the grammar of graphics,
which tries to take the good parts of base and lattice graphics and
avoid bad parts. It takes care of many of the fiddly details
that make plotting a hassle (l
> anyone please explain why this happens.. I know this happens when x1
> and x2 has different sizes. but here x1 and x2 have same dimension.
Given that this is a homework problem, I think the onus is on you to
figure this out, not on us to help you. In almost all classes, you
are expected to work
On Fri, Dec 12, 2008 at 3:08 PM, Vitalie Spinu wrote:
> On Fri, 12 Dec 2008 18:27:02 +0100, hadley wickham
> wrote:
>
>
>>> or may be just
>>> mtcars[cyl>3&last(20)]
>>>
>>> or this is already too far?
>>
>> This would be a con
> My end would be the output of your end(). If there are no args and no local
> context, I don't see the need for it to be a function call. It would just
> be defined as something like
>
> end <- structure( function(n) c(rep(FALSE, n-1), TRUE), class="selector")
Oh, I see what you mean.
> I'm n
>> Oh yes, that's a good point. But wouldn't the following do the job?
>>
>> "&.selector" <- function(a, b) {
>> function(n) a(n) & b(n)
>> }
>>
>> or
>>
>> "&.selector" <- function(a, b) {
>> function(n) intersect(a(n), b(n))
>> }
>>
>> depending on whether selectors return logical or numeric v
On Fri, Dec 12, 2008 at 11:11 AM, Vitalie Spinu wrote:
> On Fri, 12 Dec 2008 17:38:13 +0100, hadley wickham
> wrote:
>
>> You could also imagine similar iterators for random sampling, like
>> samp(0.2) to choose 20% of the indices, or boot(0.8) to choose 80%
>> with r
On Fri, Dec 12, 2008 at 11:18 AM, Duncan Murdoch wrote:
> On 12/12/2008 11:38 AM, hadley wickham wrote:
>>
>> On Fri, Dec 12, 2008 at 8:41 AM, Duncan Murdoch
>> wrote:
>>>
>>> On 12/12/2008 8:25 AM, hadley wickham wrote:
>>>>>
>>>&
On Fri, Dec 12, 2008 at 8:41 AM, Duncan Murdoch wrote:
> On 12/12/2008 8:25 AM, hadley wickham wrote:
>>>
>>> From which you might conclude that I don't like the design of subset, and
>>> you'd be right. However, I don't think this is a countere
> From which you might conclude that I don't like the design of subset, and
> you'd be right. However, I don't think this is a counterexample to my
> general rule. In the subset function, the select argument is treated as an
> unevaluated expression, and then there are rules about what to do with
>> You (as many before you) have overlooked the ave() function, which can
>> replace the ordering as well the do.call(c,tapply())
>>
>
> Majority of questions on this list concern data manipulation. Many are
> repetitive. "Overlooking" like that will always happen unless some
> comprehensive da
> Perhaps... But plyr works only on **basic** data structures, and I referred
> to all **possible** data strucures (deliberately); so I stand by my
> statement and note that you did not contradict it.
To me the basic structures are vectors, matrices and arrays; lists;
and data frames (that these a
> graphics,statistical analysis etc. as well as programming. There are just
> too many possible data structures to expect logical consistency in their
> handling throughout (if one can even define what that means in specific
> instances!).
I disagree with this claim: I think it is possible to crea
On Wed, Dec 10, 2008 at 4:09 PM, Patrizio Frederic
<[EMAIL PROTECTED]> wrote:
> hi all,
> I have a data frame such as:
>
> 1 blue 0.3
> 1 NA0.4
> 1 red NA
> 2 blue NA
> 2 green NA
> 2 blue NA
> 3 red 0.5
> 3 blue NA
> 3 NA1.1
>
> I wish to find the last non-missing value in every 3p
On Wed, Dec 10, 2008 at 1:54 PM, Viktor Nagy <[EMAIL PROTECTED]> wrote:
> 2008/12/10 Stefan Grosse <[EMAIL PROTECTED]>
>>
>> > I have two datasets stored in tab-separated format in the following way
>> > file1:
>> > country year1year2
>> > Germanyvar1 var1
>> > Hu
Hi Michael,
In general, I think you should be able to do:
gimage <- read.jpeg(url(gimageloc))
or alternatively use the EBImage from bioconductor which will read
from a url automatically (it also opens a much wider range of file
types)
library(EBImage)
img <- readImage(gimageloc, TrueColor)
Had
On Wed, Dec 10, 2008 at 11:02 AM, baptiste auguie <[EMAIL PROTECTED]> wrote:
> Dear list,
>
> I have a data.frame with x, y values and a 3-level factor "group", say. I
> want to create a new column in this data.frame with the values of y scaled
> to 1 by group. Perhaps the example below describes i
On Wed, Dec 10, 2008 at 4:33 AM, Todor Kondic <[EMAIL PROTECTED]> wrote:
> Thanks Bert for the answer! I'll try to find an appropriate package.
> In the end, i have "fiddling".
>
> But, can anyone tell me, were I to create an underlying implementation
> of cooridnate transforms, perhaps controlled
On Tue, Dec 9, 2008 at 5:36 PM, Renny Li <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I am trying to compare two values using "==" operand, please take a look of
> the following example (I copied ALL what I did here without deleting any line)
>
>>bb<-1
>> cc<-50
>> cc==abs(bb+52)
> [1] FALSE
>> C<-53
On Tue, Dec 9, 2008 at 10:39 AM, Dennis Fisher <[EMAIL PROTECTED]> wrote:
> Colleagues,
>
> Platform: OS X (but issue applies to all platforms)
> Version: 2.8.0
>
> I have a mixture of text and data that I am outputting via R to a pdf
> document (using a fixed-width font). The text contains tabs t
On Sun, Dec 7, 2008 at 10:10 AM, Daren Tan <[EMAIL PROTECTED]> wrote:
>
> How to use the na.rm function outside aggregate ? I tried
>
> na.rm <- function(f) {
> function(x, ...) f(x[!is.na(x)], ...)
> }
>
>
>>na.rm(sum(c(NA,1,2)))
>
> function(x, ...) f(x[!is.na(x)], ...)
>
>
>> na.rm(sum, c(NA,1,
>> aggregate(m[,-c(1:2)], by=list(m[,1]), mysum) <- this
>> computes correctly.
> Group.1 C D
> 1 A 3 2
> 2 B 15 13
> 3 C 10 10
> 4 D 6 7
> 5 E 9 8
>
>> aggregate(m[,-c(1:2)], by=list(m[,1]), mylength) <- this
>> computes co
On Fri, Dec 5, 2008 at 6:50 AM, Antje <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I hope this question is not too stupid. I would like to know how to update
> levels after subsetting data from a data.frame.
>
> df <- data.frame(factor(c("a","a","c","b","b")), c(4,5,6,7,8), c(9,1,2,3,4))
> names(df) <-
> I'm trying to omit NA:s in this DF and produce a reduced DF. The
> problem is that I cannot completely omit NA rows.
>
> I tried
>
> library(reshape)
> g <- melt(DF, id=c("idvar1", "idvar2"))
> g <- na.omit(g)
You're missing an id variable:
DF$idvar3 <- 1:2
g <- melt(DF, id=c("idvar1", "idvar2"
On Wed, Dec 3, 2008 at 2:06 AM, Prof Brian Ripley <[EMAIL PROTECTED]> wrote:
> On Tue, 2 Dec 2008, hadley wickham wrote:
>
>>> The underlying issue is actually not in transform() but in data.frame():
>>>
>>>> aq <- airquality[sample(1:153,6),]
>&g
Hi Daren,
Unfortunately, the current version of reshape isn't very efficient.
I'm working on a new version which should be 10-20x times faster for
the operation that you're performing, but this won't be ready for a
while and in the meantime you might want to try an alternative
approach, like the o
d an aching desire for an answer does not
> ensure that a reasonable answer can be extracted from a given body of
> data.
> ~ John Tukey
>
> -Oorspronkelijk bericht-
> Van: stephen sefick [mailto:[EMAIL PROTECTED]
> Verzonden: woensdag 3 december 2008 1:09
> Aan: ONKELI
Hi David,
> facet_wrap and facet_grid function are both very usefull. But they are
> perhaps a bit redundant.
I disagree ;) Conceptually they are rather different: facet_wrap is
essentially a 1d layout, while facet_grid is a 2d layout. This has
implications for how you specify the faceting, how
> The underlying issue is actually not in transform() but in data.frame():
>
>> aq <- airquality[sample(1:153,6),]
>> data.frame(aq, list(a=1,b=2))
> Error in data.frame(aq, list(a = 1, b = 2)) :
> arguments imply differing number of rows: 6, 1
>> data.frame(aq, list(a=1))
>Ozone Solar.R Wind
On Tue, Dec 2, 2008 at 6:21 PM, Avram Aelony <[EMAIL PROTECTED]> wrote:
> A few questions about maps...
>
> (1) How can I find a listing of the internal data sets that map() from the
> maps library contains?
> For example, "usa", "county", "state", "nz" all work. Are there any others?
help(packa
Hi Stephen,
Have a look at the "polishing your plot for publication" chapter of
the ggplot2 book.
Regards,
Hadley
On Tue, Dec 2, 2008 at 5:31 PM, stephen sefick <[EMAIL PROTECTED]> wrote:
> I would like to rotate the axis labels 45 deg.
>
> --
> Stephen Sefick
>
> Let's not spend our time and r
On Tue, Dec 2, 2008 at 9:48 AM, Antje <[EMAIL PROTECTED]> wrote:
> Hi Gabor,
>
> it works! Thank you very much! But I still don't understand the difference
> between [0-9] and [:digit:]...
You might find this site helpful:
http://regexp.resource.googlepages.com/analyzer.html
Copy in your attempt
They are obviously growing desperate - I have now been asked to write
5 articles!
Hadley
--
http://had.co.nz/
__
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/po
On Mon, Dec 1, 2008 at 12:53 PM, Reitsma, Rene - COB
<[EMAIL PROTECTED]> wrote:
> Dear All,
>
> I'm hoping one of you can help me with the following R problem. I'm
> trying to refer to a member of a list by variable. However, this seems
> not to work:
>
> foo=list(first=c(1:10),second=c(11:20))
>
>
On Mon, Dec 1, 2008 at 11:06 AM, Vitalie Spinu <[EMAIL PROTECTED]> wrote:
> Hello Everyone,
> May be a silly question.
>
> How to pass programmatically variables which are not known in advance and
> are quoted? Variables are quoted implicitly in functions like "subset" and
> "transform" and explic
On Sun, Nov 30, 2008 at 12:21 PM, Salas, Andria Kay <[EMAIL PROTECTED]> wrote:
> I am running a large for loop and at the end of each iteration a matrix is
> produced. The program changes the columns in the matrix, and each time a
> column is added the name of that column is "y". All original c
On Sun, Nov 30, 2008 at 11:38 AM, Carl Witthoft <[EMAIL PROTECTED]> wrote:
> "From: Yihui Xie
> Date: Sun, 30 Nov 2008 15:32:35 +0800
>
> Wow, you are so lazy... But sometimes R is just designed for lazy guys... "
>
>
> Yeah, well, laziness is the mother of creativity :-) .
> But seriously: I kno
On Fri, Nov 28, 2008 at 9:00 AM, Rthoughts
<[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> Is the number of lines that can be displayed in R GUI limited?
>
> When I do a Fourier Tranform of 4000 data points, I can only see the last
> 300 or so of it. I need to see all of it. How is this possible?
Perhaps y
On Thu, Nov 27, 2008 at 12:53 AM, Kinoko <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I would like to convert my "character" sequences in my matrix/
> data.frame into "numeric" where it is possible.
> I would also like to retain my alphabetic character strings in their
> original forms.
> "5.1" > 5.1
Hi Jason,
The reason you are getting this error is that the latest version of
reshape uses fun.aggregate(numeric(0)) to figure out what missing
values should be filled in with. Unfortunately there was a brief
period in R versions when var(numeric(0)) returned an error rather
than a missing value.
On Wed, Nov 26, 2008 at 8:14 AM, jim holtman <[EMAIL PROTECTED]> wrote:
> Your time is being taken up in cor.test because you are calling it
> 100,000 times. So grin and bear it with the amount of work you are
> asking it to do.
>
> Here I am only calling it 100 time:
>
>> m1 <- matrix(rnorm(1
On Tue, Nov 25, 2008 at 9:18 AM, Jacques Wagnor
<[EMAIL PROTECTED]> wrote:
> Dear List,
>
> Does there exist a function that produces a heat map like this one
> (image 3 of 4):
>
> http://www.tdameritrade.com/tradingtools/options360.html?a=HDY&referrer=http%3A%2F%2Fquery.nytimes.com%2Fsearch%2Fsite
Why not write it yourself?
days_in_year <- function(year) {
365 + (year %% 4 == 0) - (year %% 100 == 0) + (year %% 400 == 0)
}
This should work for any year in the Gregorian calendar.
Hadley
On Mon, Nov 24, 2008 at 1:25 PM, Felipe Carrillo
<[EMAIL PROTECTED]> wrote:
> Hi:
> Is there a functio
Hi Paul,
That's a bug - I'll look into it.
Regards,
Hadley
On Mon, Nov 24, 2008 at 10:46 AM, Paul Emberson <[EMAIL PROTECTED]> wrote:
> Hi,
>
> With ggplot2 v0.8, how do I position a legend on top of the plot. Things
> like
>
> p + opts(legend.position="top")
>
> work ok. But
>
> p + opts(lege
ars, geom = "line") # works
>
> qplot(mpg, wt, data=mtcars) + facet_grid(cyl ~ vs) # works
>
> qplot(mpg, wt, data=mtcars, geom = "line") + facet_grid(cyl ~ vs)
> Erreur dans grobs[[i, j]] <- layer$make_grob(layerd[[i, j]], details, coord)
> :
> types (
Hi David,
That looks like a bug! I'll look into it.
Regards,
Hadley
On Sat, Nov 22, 2008 at 1:07 PM, David Hajage <[EMAIL PROTECTED]> wrote:
> Hello R users (and Hadley)
>
> I have another question about ggplot2 :-)
>
> (version 0.8)
>
> `dat` <-
> structure(list(D = c("a", "b", "c", "d"), G =
On Sat, Nov 22, 2008 at 12:00 PM, zerfetzen <[EMAIL PROTECTED]> wrote:
>
> Goal:
> Suppose you have a vector that is a discrete variable with values ranging
> from 1 to 3, and length of 10. We'll use this as the example:
>
> y <- c(1,2,3,1,2,3,1,2,3,1)
>
> ...and suppose you want your new vector (
ggplot2
ggplot2 is a plotting system for R, based on the grammar of graphics,
which tries to take the good parts of base and lattice graphics and
avoid bad parts. It takes care of many of the fiddly details
that make plotting a hassle (l
Reading in between the lines a little, maybe you want
lm(..., na.action = na.exclude)
That should return missing values for the influence statistics when
the predictor or responses is missing in the input.
Hadley
On Thu, Nov 20, 2008 at 4:19 PM, David Kaplan
<[EMAIL PROTECTED]> wrote:
> Let me
Hi David,
I inadvertently introduced a bug in ggplot in the last release. I
uploaded a fix to CRAN this morning and it should be available in the
near future. Sorry for the inconvenience.
Regards,
Hadley
On Thu, Nov 20, 2008 at 2:49 PM, David Hajage <[EMAIL PROTECTED]> wrote:
> Hello R users,
On Thu, Nov 20, 2008 at 10:04 AM, Dieter Menne
<[EMAIL PROTECTED]> wrote:
> hadley wickham gmail.com> writes:
>
>> > library(plyr)
>> > dat = data.frame(SUBJECT_ID=sample(letters[1:5],100,TRUE),HR=rnorm(100))
>> > daply(dat,.(SUBJECT_ID),sd)
>&g
like that; I personally got used to it, but I admit
> it is one of the thinks that are unusually difficult in R.
>
> dat = data.frame(SUBJECT_ID=sample(letters[1:5],100,TRUE),HR=rnorm(100))
> sd.list = with(dat, tapply(HR, SUBJECT_ID, sd))
> data.frame(SUBJECT_ID=rownames(sd.list),sd
On Wed, Nov 19, 2008 at 5:34 PM, Juliet Hannah <[EMAIL PROTECTED]> wrote:
> With this data
>
> x <- c(0,0,1,1,2,2)
> y <- c(5,6,4,3,2,6)
> lwr <- y-1
> upr <- y+1
> xlab <- c("Low","Low","Med","Med","High","High")
> mydata <- data.frame(x,xlab,y,lwr,upr)
>
> I would like to make a dot plot and use
On Wed, Nov 19, 2008 at 12:54 PM, Brigid Mooney <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> I am iterating through dated materials, with variable start and end dates,
> and would like to skip procedures everytime I encounter a weekend or
> holiday. To do this, I thought the easiest way would be to cr
On Mon, Nov 17, 2008 at 3:49 PM, Etches Jacob <[EMAIL PROTECTED]> wrote:
> In lattice
>
> #toy data
> library(ggplot2)
> library(lattice)
> x <- rnorm(100)
> y <- rnorm(100)
> k <- sample(c("Weak","Strong"),100,replace=T)
> j <- sample(c("Tall","Short"),100,replace=T)
> w <- data.frame(x,y,j,k)
>
>
On Mon, Nov 17, 2008 at 3:42 PM, steve <[EMAIL PROTECTED]> wrote:
> Thank you. Here's my version, using melt instead of do.call(make.groups...
>
> library(reshape)
> fgl2 = melt(fgl[,-10])
> fgl2$type = fgl$type
> bwplot(value ~ type | variable, data = fgl2)
Or even more succintly:
fgl2 <- melt(f
On Sun, Nov 16, 2008 at 7:41 PM, Simon Blomberg <[EMAIL PROTECTED]> wrote:
> It is better programming practice to use FALSE for false and TRUE for
> true, and not F and T. This is because it is quite legal to do this:
>
> T <- FALSE
> F <- TRUE
It may be better programming practice, but is it bett
Hi Dave,
On Mon, Nov 17, 2008 at 6:35 AM, Dave Murray-Rust
<[EMAIL PROTECTED]> wrote:
> I'm trying to plot multiple lines using different colours/symbols to
> distinguish them. If I try to plot more than 6 lines, I get an error:
>
>> ggplot( dat, aes(x=time,y=value,group=variable,shape=variable) )
On Sun, Nov 16, 2008 at 9:56 PM, Christian Arnold <[EMAIL PROTECTED]> wrote:
> Hello R-Community,
>
> I am pretty new to R and I am fascinated what R can do! I am doing
> phylogenetic analysis in R, and my current project includes two problems
> that I am unable to solve, unfortunately. I am hoping
On Sun, Nov 16, 2008 at 8:12 PM, jeffc <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I have a data set similar to the following
>
> State Gender Quantity
> TX Male1
> NY Female 2
> TX Male3
> NY Female 4
>
>
> I need to calculate cumulative sum of the quantity by State and
Hi Stavros,
> I think we're talking past each other on the question of the semantics
> of formula operators, and it's probably not productive to continue. I
> would guess that the underlying issue is that we come from different
> communities, and so have different background assumptions. Perhaps
Hi David,
> I'm trying to learn how to make a plot with the amazing package ggplot2.
>
> I was wondering if it was possible to draw 2 (or more) x (or y) axis in the
> same graph. For example :
> - I want to show two informations at each x coordinate : a survival curve,
> I want to show the time (
On Thu, Nov 13, 2008 at 9:10 PM, J Dougherty <[EMAIL PROTECTED]> wrote:
> On Monday 10 November 2008 01:23:30 pm Prof Brian Ripley wrote:
>> See ?Sys.timezone, which help.search("timezone") points you to.
>>
>> On Mon, 10 Nov 2008, stephen sefick wrote:
>> > I have looked at
>> > ?as.POSIXct
>>
>>
> Along similar lines, someone recently posted a script to generate
> a .bib file for all packages installed. It would be useful if someone
> were to implement that script for CRAN and make the resulting
> R-packages.bib file available on the CRAN site.
It would also be useful if citation() added
On Tue, Nov 11, 2008 at 8:30 PM, Kinoko <[EMAIL PROTECTED]> wrote:
> Dear list,
>
> Is there a way to do something like the following pseudo-code -
> without for loop?
There isn't a for loop in your code!
Hadley
>
> complexFn <- function(a,b){
> ...
> return(c)
> }
>
> x[i] = complexFn(x[i-1],
> That's why (I think) it should be an *** optional argument
> with default set to FALSE *** ... it's clear from the past traffic
> on the list (I won't take the time to dig up the thread
> references right now) that there is at the very least
> a significant minority of users who expect the oppos
Which can be simplified to:
paths <- dir(path = filePath, pattern = "^test_", full = T)
lapply(paths, read.csv)
Hadley
On Tue, Nov 11, 2008 at 2:01 PM, <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> Thanks everyone for your advice. They have been helpful.
>
> Just for the record, I am using ...
>
> l
?dir
Hadley
On Tue, Nov 11, 2008 at 11:06 AM, <[EMAIL PROTECTED]> wrote:
> Dear all,
>
> I am trying to read a bunch of csv files using read.table() that are named
> "test_xx.csv" where "xx" has no particular pattern. Is there a way
> of reading all the files by specifying a truncated fi
> I think your analysis is correct, that the goals of casual use and
> programming are inconsistent. But in general I think there's always going
> to be support for providing alternative ways that are programmer-safe.
>
> For instance, library( foo, character.only=TRUE) says that foo is a
> charac
> And without wanting to be rude or anything, your opinion carries very
> little weight in a project like R. You've arrived on the list and been
> very critical of the work of others. Now there is nothing wrong with
> being critical if it is constructive, and additionally with something
> like R yo
On Mon, Nov 10, 2008 at 1:04 PM, Wacek Kusnierczyk
<[EMAIL PROTECTED]> wrote:
> pardon me, but does this address in any way the legitimate complaint of
> the rightfully confused user?
>
> consider the following:
>
> d = data.frame(a=1, b=2)
> a = c("a", "b")
> z = a
> # that is, both a and z are c(
>
> I should have been clearer, sorry-- I'm trying to exit from an "inner"
> function which might be several levels deep, returning straight to the R
> prompt. To be specific, I'm trying to clean up the "No Error in..." message
> in my 'debug' package-- the "No " prefix being my original workaro
On Mon, Nov 10, 2008 at 4:42 PM, <[EMAIL PROTECTED]> wrote:
> Dear list
>
> Can anyone suggest a simple way to abort execution like stop(...) does, but
> without issuing an "Error: ..." message?
>
> I don't want to set 'options( show.error.messages=TRUE)' because I want
> normal behaviour to res
On Fri, Nov 7, 2008 at 7:53 AM, Duncan Murdoch <[EMAIL PROTECTED]> wrote:
> On 11/7/2008 8:31 AM, roger koenker wrote:
>>
>> Those of you with an interest in the US election and/or
>> statistical graphics may find the maps at:
>>
>>http://www-personal.umich.edu/~mejn/election/2008/
>>
>> in
see ?xfig.
>
> Best,
>
> Philippe
> ..<°}))><
> ) ) ) ) )
> ( ( ( ( (Prof. Philippe Grosjean
> ) ) ) ) )
> ( ( ( ( (Numerical Ecology of Aquatic Systems
> ) ) ) ) ) Mons-Hainaut University, Belgium
> ( ( ( ( (
> ...
On Thu, Nov 6, 2008 at 10:05 AM, Max Kuhn <[EMAIL PROTECTED]> wrote:
>> * svg: R output devices still experimental
>
> I've been using the svg device in the Cairo package for a while now.
> I've never had any issues with it and wouldn't characterize it as
> experimental (of course, others may have
Hi all,
I'm trying to write up some recommendations for what graphics formats
are most useful for inclusion into ms office and openoffice. There
have been a few discussions on the list in the past, but I haven't
seen a summary. These are the options I've seen so far, along with
there costs and b
On Wed, Nov 5, 2008 at 11:12 AM, pilar schneider
<[EMAIL PROTECTED]> wrote:
> Dear all
> I need some help with R.
> How can I save the estimates of a regression model in a file?
>
> here is what I did:
>
> 1) this is my regression model:
> fit1 <- lm(logmilk ~ logdays + days, data=data2)
>
> 2) how
On Wed, Nov 5, 2008 at 5:42 AM, Fredrik Karlsson <[EMAIL PROTECTED]> wrote:
> Dear list,
>
> Sorry to ask you this, but I just ran a TukeyHSD on an model with a
> two thee level factors as independent variables and a numeric score
> dependent variable.
> The aov gives a significant interaction effe
Hi Simeon,
Could you publish vixarchive.csv too please? Do you have a start on
the version in ggplot2? It would be useful to see that code too.
Hadley
On Tue, Nov 4, 2008 at 8:49 AM, simeon duckworth
<[EMAIL PROTECTED]> wrote:
> Dear "R-listers"
>
> I've been trying to figure out how to annotat
v 4, 2008 at 9:25 AM, hadley wickham <[EMAIL PROTECTED]> wrote:
>> Hi Stephen,
>>
>> Thanks for the bug report (and apologies for the delay getting back to
>> you). I'm working on a fix today and will hopefully release a new
>> version in the very nea
> plotmatrix(d[,3:6])
>
> I would like to either have a colour or more preferably a shape to
> correspond to Site
> this is what I have tried (along with many other combinations)
> plotmatrix(nmds.bug[,3:6])+scale_shape(nmds.bug, shape=Site, pch=1:12)
There's not really any easy way to do this in
Hi Stephen,
Thanks for the bug report (and apologies for the delay getting back to
you). I'm working on a fix today and will hopefully release a new
version in the very near future.
Hadley
On Fri, Oct 31, 2008 at 12:51 PM, stephen sefick <[EMAIL PROTECTED]> wrote:
> Hadley et al.,
> I was using
Is your variable actually a date? R doesn't recognise dates
automatically - you need to create them with as.Date or similar.
Hadley
On Tue, Nov 4, 2008 at 3:22 AM, <[EMAIL PROTECTED]> wrote:
>
> Dear all,
>
> In the x-axis of a xyplot I define dates ,for example 01-10-2007 instead of
> numbers
On Mon, Nov 3, 2008 at 9:02 AM, Jorge Ivan Velez
<[EMAIL PROTECTED]> wrote:
> Dear zerftezen,
> Try this:
>
> # Data
> set.seed(123)
> X=as.data.frame(matrix(rnorm(100),ncol=10))
>
> # Percentiles 10 and 90 using apply
> t(apply(X,2,quantile,probs=c(0.1,0.9)))
>
> # The same using sapply
> t(sapply
Hi Carlos,
I'd strongly urge to reconsider your colour choices - 7-10% of males
are red-green colour blind and it will be difficult for them to tell
the difference between the high and low values.
Hadley
On Sat, Nov 1, 2008 at 11:58 PM, Carlos Morales
<[EMAIL PROTECTED]> wrote:
> Hello everyone,
On Fri, Oct 31, 2008 at 11:25 AM, Philip Twumasi-Ankrah
<[EMAIL PROTECTED]> wrote:
> Hi friends,
> I need suggestions/directions on how to producing a waterfall plot for
> present extend of change in tumour size for a set of respondents in a study.
> Example of use of waterfall plot is in the fo
On Sat, Nov 1, 2008 at 5:13 AM, baptiste auguie <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I believe you can apply the same procedure as described in Paul Murrell's "R
> graphics" book for arranging lattice plots.
Yup, and see also http://had.co.nz/ggplot2/book/grid.pdf
Hadley
--
http://had.co.nz/
> For this example:
>
> library(ggplot2)
> p <- ggplot(mtcars, aes(x = wt, y=mpg)) + geom_point()
> p <- p + scale_x_continuous(expression(beta))
> p
>
> How can I include text with the expression. For example, "level of
> \beta". Also, how can I increase
Have a look at ?plotmath - you want someth
901 - 1000 of 1519 matches
Mail list logo