You actually want cast() from the reshape package, not melt().
I would recommend using dcast() from reshape2, the newer version of reshape.
Jean-Olivier Irisson
—
Université Pierre et Marie Curie
Laboratoire d'Océanographie de Villefranche
181 Chemin du Lazaret 06230 Villefranche-sur-Mer
Tel: +33
Do you mean supervised or unsupervised classification.
If supervised, I have had great success using gradient boosted
classification in package gbm. multinomial distribution will get you
multiple classes and it will select relevant predictors by itself
given the training data.
Not sure about the
se guicktime on Mac OS X or mencoder on Linux/OS
X. I don't know about Windows.
Since mencoder works on the command line, you can call it from R and I
have code to ease that:
https://gitorious.org/r/r-utils/blobs/master/lib_movie.R
but you should get familiar with mencoder a l
way to include that in an object of class "htest"? I see
in print.htest() that the p.value element goes through format.pval()
which expect a numeric argument. Is there any workaround?
Thank you in advance. Sincerely,
JiHO
---
http://maururu.net
___
aning when a quadratic term or
an interation is involved, and why they should not be removed in most
circumstances. I haven't found anything related to quadratic vs.
interactions.
Thanks in advance for your help. Sincerely,
JiHO
---
http://maururu.net
___
f I could compute this, I am
not sure how I would plot the result. My goal is really to add this to
my R-plotting arsenal and use it in routine, not to develop something
very specific for this particular application. But thank you for
taking the time to reply, maybe I'll c
alpha = alpha/5
# plot
library("rgl")
spheres3d(d$x, d$y, d$z, alpha=alpha, radius=0.05)
I saw the fog effect but it seems to add a fog in the scene to
increase depth. What I want is my scene to actually look like a fog.
Thanks in advance for
it needs a numeric vector and does
not automatically convert your data.frame into it. So you need:
mean.default(as.numeric(temp[2,2:3]))
or more simply
mean(as.numeric(temp[2,2:3]))
I hope that helped. Sincerely,
JiHO
---
http://maururu.net
ry much in advance.
PS: what I did so far was just compute mean +/- SD. The result is here:
http://dl.dropbox.com/u/1047321/hist_mean-SD.pdf
Maybe the SD is already so large that it is not even worth trying to
pursue my goal above...
Sincerely,
JiHO
---
http://m
ut correct size. I currently chose the fonts over the size since the
size can be corrected and the fonts cannot. BUt of course I would
rather not have to choose ;)
JiHO
---
http://maururu.net
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailma
to add a
'scale' argument to includegraphics in latex for those. I would rather
leave the latex document alone, use extension-less file names
includegraphics and decide from R wether to produce a pdf or a png.
Thank you in advance,
JiHO
---
http://maururu.net
___
"in one step" I meant within the merge, not in one post-
processing step ;)
JiHO
---
http://maururu.net
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-projec
r fonction that would do that or do I have to resort to
some post-processing after merge? It seems that it might be something
like a "right merge" for data bases but I don't know this world at
all. I would be happy to look into sqldf if that allows to do things
like that.
them. Maybe
that's specific to Cream.
JiHO
---
http://jo.irisson.free.fr/
__
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 pr
the default X-term to gnome-terminal. You have to edit
the file .vim/ftplugin/r.vim. There is a line commented with the gnome-
terminal command instead of xterm. Uncomment this one and comment the
xterm one.
JiHO
---
http://jo.irisson.free.fr/
_
omputed with QB and actually closer to yours.
Looking at your code I still don't get what I am doing wrong though.
It seems we both use sample to get a few of the columns and then swap
them. Well, I'll use your test anyway.
JiHO
---
http://jo.irisson.free.fr/
___
quot;text")
}
# Compute the syrjala stat for the observations
psi = syrjala.stat(dataCod)
# Estimate the pvalue
pvalue = (sum(psis>=psi)+1)/nperm
psi
pvalue
# Should be:
# statistic = 0.224
# p-value = 0.1900
Thank you very much in advance. Sincerely,
JiHO
---
h
On 2009-April-30 , at 22:28 , Gabor Grothendieck wrote:
Check out the getopt package.
Thanks! That's what I need.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEA
and all that but
did not find anything. Is that possible?
Otherwise I will resort to parsing the arguments with strsplit but I
would much prefer and more elegant solution.
Thank you very much in advance. Sincerely,
JiHO
---
http://jo.irisson.free.fr/
imple keyboard
shortcut in my text editor to source the current file in the currently
R session, so it will be easy to re-source some files after I modify
them.
On the other hand I have a bundle of general enough functions that I
import in many projects (http://github.com/jiho/r-utils/ for
rce(lib)
}
}
but I am really not confident with all those deparse/substitute things
and the environment manipulation, so I guess there should be a better
way.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://sta
just want to print a
clean output on the screen? If yes, look at `cat`, or `print`.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://
.652199 0.579333"), sep=" ")
# you would use scan with the filename in which the data is, rather
than the textConnection. That's just for the purpose of the
demonstration here.
# possible outputs
congeneric[1:20]
as.list(congeneric[1:20])
for (i in 1:20) {
with that?
What do you need the list for? It would help to know (a bit) of the
general context to help you.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the
what you just asked:
http://had.co.nz/ggplot2/geom_jitter.html
look at the end. As for transparency, you can use
geom_boxplot(fill=alpha("white",0.5)) for example.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mai
ata.frame
dat = data.frame(v=wV[0:15,3], y=wY[0:15,3],
sign=ifelse(wY[0:15,3]>0,">0","<0"))
ggplot(data=dat) + geom_point(aes(x=v,y=y,colour=sign))
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
h
On 2008-February-11 , at 21:06 , Charilaos Skiadas wrote:
> JiHO, in case you are not following TextMate's mailing list, you
> might want to check out Hans-Jorg Bibiko's work on Rdaemon:
>
> http://article.gmane.org/gmane.editors.textmate.general/24195/
>
> It pr
6.2
>> year 2008
>> month 02
>> day08
>> svn rev44383
>> language R
>> version.string R version 2.6.2 (2008-02-08)
>>
>>
>>> installed.packages()
>>
>> reshape
ou don't use only R, you can keep the same habits
with a nice editor.
I haven't tried Emacs+ESS. I've heard a lot of good things about it
but learning Emacs is a task in itself.
[1] http://macromates.com/
[2] modification of those http://j
ease include me in the
> distribution list?
>
> Thanks much!
Begin forwarded message:
> From: jiho <[EMAIL PROTECTED]>
> Subject: Comparing spatial point patterns - Syrjala test
>
> Dear Lists,
>
> At several stations distributed regularly in space[1], we sa
On Feb 9, 2008 10:39 PM, milton ruser <[EMAIL PROTECTED]> wrote:
> I have no idea of how to solve this issue, but I suggest you write to the
> authors of spatstat package. I think they could help you very much. Another
> thing is that there was a threhead on this many times ago. May be that Alan
>
Dear Lists,
At several stations distributed regularly in space[1], we sampled
repeatedly (4 times) the abundance of organisms and measured
environmental parameters. I now want to compare the spatial
distribution of various species (and test wether they differ or not),
or to compare the dis
On 2008-February-06 , at 14:45 , Duncan Murdoch wrote:
> On 2/5/2008 11:12 AM, jiho wrote:
>> Dear List,
>> I am trying to get R's terminal output to a file and to the
>> terminal at the same time, so that I can walk through some tests
>> and keep a log
commands in a .R file and source it to execute it. In this case the
transcript would only contain "source("whatever.R", print.eval=T)"
which won't be very informative :/. And in the case of sourcing, the
problem with disappearing text stays the same.
Tha
hands) would be to have reviews in a wiki form: review text
editable + comments.
- some tag reviews. they would essentially serve the purpose of Task
Views but would probably be more dynamic (since the number of packages
linked to a tag can change) and integrate with the rest.
(Thanks for
37929 1.600
>
Is this a known bug (I'm using R 2.6.1 on OS X and Linux - FC8)? Is
there an inherent reason why some portions of this output are not
redirected?
Thank you in advance for your help.
JiHO
---
http://jo.irisson.free.fr/
__
ure.
> But I think the answer is in the help for options(), and more
> obvious from ?chooseCRANmirror (which seems to be one of the
> functions you are using).
Indeed, the option to set is menu.graphics=FALSE
Thank you very much!
> On Tue, 5 Feb 2008, jiho wrote:
>
>>
). This may
give you the reason behind this seemingly strange question.
JiHO
---
http://jo.irisson.free.fr/
__
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
ta.frames directly. Is there
such a modified apply in some package?
[1] ?apply says
"If X is not an array but has a dimension attribute, apply attempts to
coerce it to an array via as.matrix if it is two-dimensional (e.g.,
data frames) or via as.array."
JiHO
---
http:/
on (if someone knows it) for the current
behaviour of merge?
Thanks in advance.
PS: code
a = data.frame(field1=c(1,1,2,2),field2=c(1:2,1:2),var1=runif(4))
b = data.frame(field1=c(2,2,1,1),field2=c(1,2,2,1),var2=runif(4))
a
b
merge(b,a)
merge(b,a,sort=F)
b = rbind(b,b[1,])
b
merge(b,a,sort=F)
Ji
would welcome suggestions. Thank you in advance.
JiHO
---
http://jo.irisson.free.fr/
__
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
ction (since its purpose is documentation) but overlaying two
graphs is often as simple as adding them:
p <- ggplot(mtcars, aes(x=wt, y=mpg)) + geom_point()
g <- geom_path(aes(x=wt,y=mpg, colour=qsec))
p + g
(this example is probably useless but it is only for demonstration
pu
=c(0,1))
which has no effect. but the side effect of enforcing the square
domain is that:
ggplot(data=a, aes(x=x,y=y)) + geom_point() + coord_equal() +
scale_y_continuous(limits=c(0,0.3))
has no effect either (i would expect to see only the points <0.3)
JiHO
---
http://jo.irisson.free
9 93.5
4 4 17 140.2
4 1 1 90.3
4 1 9 36.5
4 1 17 55.1
7 4 1 169.1
7 4 9 718
7 4 17 813
7 1 1 73.4
7 1 9 46.5
7 1 17 205
to you shell startup script (.profile, .bashrc whatever) so that the
display variable is defined. You'll have to start X11 manually but
once it is started, you should be able to run X11 apps directly from
Terminal.app
Hope that helps.
JiHO
---
http://jo
On 2007-December-13 , at 15:56 , hadley wickham wrote:
> Hi Jiho,
>
> The key to solving this problem is to use aes_string instead of aes.
> Instead of the complicated munging that aes does to get the names of
> the variables, aes_string works directly with strings, so that:
&
Follow up.
On 2007-December-13 , at 10:45 , jiho wrote:
> foo1 <- function(uv="u")
> {
> # solution 1: do not use the data argument at all
> # (forces the use of qplot, could be more elegant)
> B = A[A$y<=5,]
> qplot(
y<=5,],aes(x=x,y=y,fill=???)) + geom_tile()
# or ...
}
print(foo1("u"))
print(foo1("v"))
print(foo2("u"))
print(foo3("u"))
#
Any help in making foo3 work would be appreciated. Thanks in advance
for your expertise.
JiHO
---
h
am I not a Mac OS
> user and I did check the archives but found mostly discussions on
> X11() under Mac OS X.
>
> Wayne
>
> __
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting gui
rinciple holds.
Thanks very much. I'll test this soon (and it looks like the vector
operation might even be directly translatable in Fortran which is
nice since I'll need to do it in Fortran too).
Thanks again.
JiHO
---
http://jo.irisson.free.fr/
__
self in a probably highly specialized and not reusable
manner.
Thank you very much for you answer and if someone knows a function
doing what is described above, that would be terrific.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org m
(but I am sure the solution to this is
generic enough to work in nD)
Thank you in advance.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-
scape so it is fine on
this side. The only "problem" with this workflow for me is that many
of my plots stay between stage 1 and 2 and I like to be able to view
them quickly. I would need a quick SVG viewer but there are none on
OS X. If you are on Linux, many documents
draws real
circles) so I would rather not tweak the rest to get the pdf right.
Thanks anyway.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www
Thank you very much for your answer, even so long after I first
posted the message.
On 2007-October-31 , at 12:00 , Paul Murrell wrote:
> Hi
>
> jiho wrote:
>> Hello all,
>> I discovered that the pdf device uses fonts to represent "points"
>> symbols (a
linux replacement and ditch my
half-bitten apple for a penguin.
[1] http://jo.irisson.free.fr/?p=32
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guid
t.pdf","pdfwrite","test_embed.pdf")
visualize the fonts:
pdffonts test.pdf
and a package with the two pdf files and bitmaps of how they render
or are interpreted in various programs:
http://jo.irisson.free.fr/
On 2007-October-01 , at 23:13 , jiho wrote:
> [...]
> The end result looks like this:
> http://cbetm.univ-perp.fr/irisson/svn/
> to see what an inner view looks like:
> http://cbetm.univ-perp.fr/irisson/svn/distribution_data/tetiaroa/
> trunk/data/?rev=0&sc=1
First a quick summary of the beginning of an interesting discussion
(not all indented correctly but in the correct order at least):
> From: "Gabor Grothendieck" <[EMAIL PROTECTED]>
> On 9/30/07, hadley wickham <[EMAIL PROTECTED]> wrote:
>> On 9/30/
27;x'height' is printed. The only
relations between the paper argument and the device size arguments are:
- when using the default size "special"
- when the device size is > paper size, in which case the device is
resized to fit on the paper sheet
I would also like the
ided that the 'arrow' argument is
>> passed on to segmentsGrob which is used in geom_segment.
>
> In general, ... doesn't get passed on to the underlying grid function
> because there isn't a one-to-one mapping from geoms to grobs (take
> geom_boxplot for example
This was meant to be sent on the list:
On 2007-September-30 , at 23:12 , jiho wrote:
> On 2007-September-30 , at 21:01 , hadley wickham wrote:
>>>> [...]
>>> As expected there is nothing in the data part of the p object
>>>> p$data
>>> NULL
>>
ing
small bugs is probably more efficiently done by a team than by a
single person, with little free time. Furthermore, most of these
things can be done without deep knowledge of the architecture of
ggplot2.
I probably won' t be able to make significant contributions before a
whi
rop=T)
>> which would give p1 and p2 plots clipped to the xlim and ylim of p2.
>
> Yes, it would be nice to have some syntax to overrule the default
> policy of showing all the data, although it gets a bit more
> complicated when you consider other scales like colour and size.
I
On 2007-September-28 , at 18:25 , Frank E Harrell Jr wrote:
> jiho wrote:
>> On 2007-September-28 , at 16:57 , Frank E Harrell Jr wrote:
>>> jiho wrote:
>>>> On 2007-September-28 , at 15:18 , Paul Smith wrote:
>>>>> On 9/28/07, Prof Brian Ripley <
On 2007-September-28 , at 16:57 , Frank E Harrell Jr wrote:
> jiho wrote:
>> On 2007-September-28 , at 15:18 , Paul Smith wrote:
>>> On 9/28/07, Prof Brian Ripley <[EMAIL PROTECTED]> wrote:
>>>>> I know how to export graphics as pdf files and then how t
on all my R graphics because I find it
easier and quicker to get decent graphics and R and refine their look
in Inkscape than to get them perfect in R in one shot ( though with
ggplot2 things are improving on R's side).
Cheers,
JiHO
---
http://jo.irisson.free.fr/
___
produce the plot in several steps, otherwise it will
soon become too complicated to manage.
Thank you very much in advance for your help.
JiHO
---
http://jo.irisson.free.fr/
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r
=wt, x=qsec)) + geom_point() + ???
Indeed the ggplot syntax is in general more flexible and powerful and
I usually rely on it in scripts. It would be nice to know how to use
xlim/ylim with this syntax.
Thank you in advance.
JiHO
---
http://jo.irisson.f
69 matches
Mail list logo