Merci Arun
Michel
Le 17/09/2013 22:41, arun a écrit :
Hi Arnaud,
You could also try:
indx- Df1$Mat[-1]==Df1$Mat[-nrow(Df1)]
indx1-c(indx,FALSE)
indx2-c(FALSE,indx)
Df1[indx1,]
Df1[indx2,]
A.K.
From: arun smartpink...@yahoo.com
To: Arnaud Michel
Oh,yes, I found out this according to your reply.Thanks.
As to time series analysis, in order to show the effect of smoothing or
filtering,the common command is:
plot(ts0);
lines(fitted(...))
But not lines(fitted(...) ~ time(ts) )
How to understand this then?
Many thanks.
Best.
At
Hi,
I want to change my geom.point shapes in facet grid. I have tried all sorts of
solutions, but for some reason none seem to work. Something overrides the
normal codes. I am stuck.
I have attached the data to the mail.
I want organism to have different shapes and then add a legend to the
Hi All,
I need to construct a stacked bar plot with two independent (x) variables,
where the stacking is x1 and the x-axis label is x2. Can someone help out
with the code for this or provide a reference/example?
Thank you,
J
--
View this message in context:
On Tue, 17 Sep 2013, Carabiniero wrote:
Hi All,
I need to construct a stacked bar plot with two independent (x) variables,
where the stacking is x1 and the x-axis label is x2. Can someone help out
with the code for this or provide a reference/example?
I'm not completely sure what exactly you
Hi,
What does every line mean especially the expression
[1L], [2L], and
(1L:p, 1L:p)
1L, 2L etc are integers. (That is, identical to as.integer(1) ,
as.integer(2) etc)
Using integers (instead of numeric type) is more efficient as here
they're used as indexes and would be converted to integer
Hello,
Please have a look at:
http://cran.r-project.org/doc/manuals/R-lang.html#Constants
Hope this helps,
Pascal
2013/9/18 Pascal Oettli kri...@ymail.com
Hello,
Apologies. findFn('cov2cor') did not find it...
Regards,
Pascal
2013/9/18 Pascal Oettli kri...@ymail.com
Hello,
Hello,
It's a function of package sos, quite useful to find functions in R.
Regards,
Pascal
2013/9/18 Kenn Konstabel lebats...@gmail.com
Hi,
What does every line mean especially the expression
[1L], [2L], and
(1L:p, 1L:p)
1L, 2L etc are integers. (That is, identical to
On Sep 18, 2013, at 00:22 , Jeff Newmiller wrote:
You seem to be applying the syntax for the within function to the with
function. You should compare the documentation for them and choose your
approach accordingly.
The syntax is fine, the difference in within() is that you can do
http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example
John Kane
Kingston ON Canada
-Original Message-
From: algara...@gmail.com
Sent: Wed, 18 Sep 2013 10:06:23 +0800
To: r-help@r-project.org
Subject: [R] (no subject)
Good morning,
I am an
Does this questions help
http://stackoverflow.com/questions/1478532/changing-shapes-used-for-scale-shape-in-ggplot2
?
It looks like it does but I don't have time at the moment to work it out with
your code.
Good luck
John Kane
Kingston ON Canada
-Original Message-
From:
On 13-09-18 1:38 AM, meng wrote:
Oh,yes, I found out this according to your reply.Thanks.
As to time series analysis, in order to show the effect of smoothing or
filtering,the common command is:
plot(ts0);
lines(fitted(...))
But not lines(fitted(...) ~ time(ts) )
How to understand this then?
Hi,
Dummy data script and scripts are attached below.
I would like to change the plot to look like this:
I have a data set with 20K variables. I want to apply Boruta feature
selection but I get cannot allocate vector of size error. Hence, I decided
to use bigmemory like below script but it seems that Boruta does not accept
a pointer. How can I apply feature selection to 20K variables?
df - data with
Does anyone know of a package that would allow data from a CT scan to be
loaded into R?
Thanks!
--
View this message in context:
http://r.789695.n4.nabble.com/R-packages-for-CAT-scans-tp4676418.html
Sent from the R help mailing list archive at Nabble.com.
Hi,
I have a vector that looks like this;
(imported from another file)
dates - c(Tue Sep 17 2013 16:25:17, Wed Sep 18 2013 16:35:17, Thu Sep 19
2013 16:55:17)
now I need a data frame with two columns;
datetime
2013.09.17 16:25:17
2013.09.18
You're right! QFMFT!
:-)
Thanks
2013/9/17 Rolf Turner rolf.tur...@xtra.co.nz
On 09/18/13 07:26, Arnaud Mosnier wrote:
Hi all,
I want to present a figure including the uppercase and lowercase version
of
the greek letter phi.
I know that I can use expression to have the symbol like in:
Thanks Murdoch. I tried PHI but not Phi.
Arnaud
2013/9/17 Duncan Murdoch murdoch.dun...@gmail.com
On 17/09/2013 3:26 PM, Arnaud Mosnier wrote:
Hi all,
I want to present a figure including the uppercase and lowercase version
of
the greek letter phi.
I know that I can use expression to
HI,
May be this helps:
vec1-as.POSIXlt(strptime(gsub(^\\w+ ,,dates),%b %d %Y %H:%M:%S))
dat1- data.frame(date= gsub(-,.,as.Date(vec1)), time=
strftime(vec1,format=%H:%M:%S)
,stringsAsFactors=FALSE)
dat1
# date time
#1 2013.09.17 16:25:17
#2 2013.09.18 16:35:17
#3 2013.09.19 16:55:17
Hello all,
A very simple problem.
Lets assume I have an interval [0,1] and I split it in 6 bins having
thresholds:
pro= cbind(0, 0.3675509, 0.8618615, 0.9814291, 0.9975283, 0.9997789,
1.000,
0, 0.3662881, 0.8609743, 0.9812032, 0.9974822, 0.9997738,
1.000)
dim(pro)-c(7,2)
Check here: http://cran.r-project.org/web/views/MedicalImaging.html
Bryan
On Sep 18, 2013, at 7:56 AM, wwreith reith_will...@bah.com wrote:
Does anyone know of a package that would allow data from a CT scan to be
loaded into R?
Thanks!
--
View this message in context:
On 09/18/2013 10:43 PM, ioanna ioannou wrote:
Hello all,
A very simple problem.
Lets assume I have an interval [0,1] and I split it in 6 bins having
thresholds:
pro= cbind(0, 0.3675509, 0.8618615, 0.9814291, 0.9975283, 0.9997789,
1.000,
0, 0.3662881, 0.8609743, 0.9812032,
On 18-09-2013, at 14:43, ioanna ioannou ii54...@msn.com wrote:
Hello all,
A very simple problem.
Lets assume I have an interval [0,1] and I split it in 6 bins having
thresholds:
pro= cbind(0, 0.3675509, 0.8618615, 0.9814291, 0.9975283, 0.9997789,
1.000,
0, 0.3662881,
Hi Anna,
It's not clear to me what you are trying to do. If you want different
shapes for different organisms then you should map organism to shape,
e.g.,
geom_point(data = Summisodata11, aes(y = mean, shape=organism))
Is that what you are looking for? If not please restate the question.
Hi Anna,
See in line below.
On Wed, Sep 18, 2013 at 7:29 AM, Anna Zakrisson Braeunlich
anna.zakris...@su.se wrote:
Hi,
Dummy data script and scripts are attached below.
I would like to change the plot to look like this:
Hi Elio,
Try this:
Assuming that there is a single blank row separating the matrices:
lines1- readLines(textConnection(aa5 aa10 b253 b254
aa5 0 1 1 1
aa10 1 0 1 1
b253 1 1 0 1
b254 1 1 1 0
aa5 aa9 b27
Hi,
Try:
lapply(paste0(m,1:2),function(x) {png(file=paste0(plot,x,.png));
plot(get(x),pages=1,shade=TRUE);dev.off()})
#change 1:2 accordingly
A.K.
I wanted to plot a gam object output and save the plots in a folder. I have
several such objects in the workspace and wanted to automate the
Hi,
Try: set.seed(49)
t(sapply(seq_len(ncol(pro)),function(i) {ids- runif(1);
x1-cut(ids,breaks=pro[,i]); c(ids=ids,bin_location=x1)}))
# ids bin_location
#[1,] 0.3656991 1
#[2,] 0.4878542 2
A.K.
- Original Message -
From: ioanna ioannou
On my systems Linux Scientific and Mac OS X I use as well for the F77 the
gfortran compiler and this works. You could give it a trial.
Best
Simon
On Sep 18, 2013, at 3:14 PM, Prigot, Jonathan jpri...@partners.org wrote:
I am trying to build R-3.0.1 on our SPARC Solaris 10 system, but it
Hi,
I have a pair-wise distance vector. FOr objects: a,b,c, it is: (a,b) :5,
(b,c) :6, (a,c) : 7. I want to convert it into a symmetric matrix. I
used cast function but the function does not fill the matrix like a
triangular matrix. How do I get a symmetric matrix?
--
--Taraka
Hi,
I find this behavior unexpected:
--8---cut here---start-8---
strsplit(c(a,b;c,d;e,f),c(,,;))
[[1]]
[1] a b;c
[[2]]
[1] d e,f
--8---cut here---end---8---
I thought that it should be identical to this:
I am trying to build R-3.0.1 on our SPARC Solaris 10 system, but it
fails part way through with g77 errors. Has anyone run into this? Any
suggestions? For what it's worth, R-2.15.1 is the last one to build
error free for us.
===
Jon Prigot
R is now configured for sparc-sun-solaris2.10
Source
Hi,
I have another question related to the same problem. I have a text file
with about 350 matrices each separated by a blank row. My question is how
to make R believe each matrix is separate and has a specific name m1,
m2,m350. Below is an example:
aa5 aa10 b253 b254 aa5 0 1 1 1 aa10 1 0
On Sep 18, 2013, at 10:42 AM, Sam Steingold s...@gnu.org wrote:
Hi,
I find this behavior unexpected:
--8---cut here---start-8---
strsplit(c(a,b;c,d;e,f),c(,,;))
[[1]]
[1] a b;c
[[2]]
[1] d e,f
--8---cut
What do you get with:
sample$x * coef(s_model)[-1]
On Tue, Sep 17, 2013 at 3:09 AM, å²³èµ yue...@139.com wrote:
hello all
I am really confusing that how predict(,type = terms,) gets the desired
result. For example,
sample - matrix(nrow = 10, ncol = 2)
colnames(sample) - c(y,x)
On 09/18/2013 09:04 AM, arun wrote:
Hi,
You could try:
strsplit(c(a,b;c,d;e,f),,|;)
He did it with [,;] which is equivalent but slightly faster. The more
characters you have inside the square brackets, the more beneficial it
is to use [abcde] over a|b|c|d|e. It's also more compact and easier
Hi,
It is not clear whether it is a data frame or vector. Please use ?dput() to
show the example dataset.
vec1- 5:7
mat1- matrix(0,3,3,dimnames=list(letters[1:3],letters[1:3]))
mat2- mat1
nm1- c(ab,bc,ac)
vec2-paste0(colnames(mat1)[col(mat1)],rownames(mat1)[row(mat1)])
Hi,
You could try:
strsplit(c(a,b;c,d;e,f),,|;)
#[[1]]
#[1] a b c
#
#[[2]]
#[1] d e f
A.K.
- Original Message -
From: Sam Steingold s...@gnu.org
To: r-help@r-project.org
Cc:
Sent: Wednesday, September 18, 2013 11:42 AM
Subject: [R] strsplit with a vector split argument
Hi,
I find
You need to tell us what the objects are. Are they vectors of some
type of data? If so, what type, etc..
At least provide a subset of the data using 'dput' so we know what we
are looking at.
The 'if' statement will work fine is the objects are single valued;
you will need a different
On possible way, if I understand the question correctly, is to use the
findInterval() function.
Otherwise, solutions depend on details you haven't included.
Here's an example from ?findInterval
x - 2:18
v - c(5, 10, 15) # create two bins [5,10) and [10,15)
cbind(x, findInterval(x, v))
The code below uses ggplot with stat_smooth(method=glm,
family=binomial, ...)
to plot the data on survival of passengers on the Titanic, with the
logistic regression
curves for each sex on the scale of Pr(survived). This works (quite
nicely!) because
I've explicitly transformed the factor
Hi,
Try:
all[which.max(all$income),c('names','age')]
# names age
#2 Jim 25
A.K.
Hi everyone
I'm new to R, so this is probably a stupid question, but I looked
around for quite a while an couldn't find an answer. Basically I'm
trying to print values that correspond to a found maximum.
Hi there,
I want to know the radius of curvature for a set of points, but cannot
figure out how to perform the fit in R.
I have a set of points P_i for which I want to calculate the radius of
curvature. The coordinates (x_i|y_i) of the points in a data.frame:
p - data.frame(
x = c(113, 143,
Hi there,
I have recently installed the latest R version 3.0.1, replacing the previous
version 2.15.2.
Just as I am running R I get a few warnings about packages that I have
previously used.
Below I attach the session info a long with the warnings I am getting.
What does these warnings mean?
Hello all,
I am trying to do a one-to-many Spatial Join with PolyLines and Polygons. I
have about a couple of thousands of PolyLines (streets) and I want to assign
them all the Polyogons (regions) they cross or touch.
I know this is possible in ArcGIS, do you have any idea how this is possible
I am currently working a meta-analysis that is exploring the effect of a drug
on plasma lipid levels. However, I am primarily interested in assessing the
overall dose-response relationship with mean change in lipids. I have used the
metafor package to conduct a meta-regression but is there a
Ok, Thanks foe the answer, Ken:
*1L, 2L etc are integers. (That is, identical to as.integer(1) ,
as.integer(2) etc)
Using integers (instead of numeric type) is more efficient as here they're
used as indexes and would be converted to integer anyway.
Compare
is(1)
... and
is(1L)
1L:p is the
Hi everyone
I'm new to R, so this is probably a stupid question, but I looked around for
quite a while an couldn't find an answer. Basically I'm trying to print
values that correspond to a found maximum.
If I have this:
names - c(John, Jim, Mary, Susan)
age - c(16, 25, 32, 56)
income - c(2000,
If I have this:
names - c(John, Jim, Mary, Susan)
age - c(16, 25, 32, 56)
income - c(2000, 3000, 2500, 1500)
all- data.frame(names, age, income)
First, things will be easier for you if you make that dataset as
all - data.frame(
names = c(John, Jim, Mary, Susan),
Thanks a lot to you both.
Both solutions work great, and thanks to will for explaining how this
works. I will have a look into while and if statements in R tomorrow...
2013/9/18 William Dunlap [via R] ml-node+s789695n4676466...@n4.nabble.com
If I have this:
names - c(John, Jim, Mary,
hello,
This
rbindlist(list(list(a=NA,b=NA),list(a=20,b=FALSE)))
returns
a b
1: NANA
2: TRUE FALSE
as per the documentation ?rbindlist
is there a way to specify the column class of 'a' to be numeric?
In actual usage, i wont be able to re-order the 2nd list entry to be the
I'd suggest you ask this question on r-sig-geo
-Don
--
Don MacQueen
Lawrence Livermore National Laboratory
7000 East Ave., L-627
Livermore, CA 94550
925-423-1062
On 9/18/13 9:44 AM, jas jacqueline.schwei...@wuestundpartner.com wrote:
Hello all,
I am trying to do a one-to-many Spatial
Hello,
I am just wondering why to reinvent the wheel?
Regards,
Pascal
2013/9/19 wacguy g...@duke.edu
Ok, Thanks foe the answer, Ken:
*1L, 2L etc are integers. (That is, identical to as.integer(1) ,
as.integer(2) etc)
Using integers (instead of numeric type) is more efficient as here
I would stay away from learning about 'while' and 'if' until you
understand using '[' to select subsets. Subsetting is in chapter 2
of An Introduction to R and 'while' and 'if' are in chapter 9 for
good reason.
Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com
-Original Message-
Hello,
You can use the function circlefit from pracma. The example is adapted
from the help page to fit your data.
#---
require(pracma)
xp - c(113, 143, 184, 229, 290, 342, 393, 456, 540, 618)
yp -
Hi,
Try:
rbindlist(list(list(a=NA_integer_,b=NA),list(a=20,b=FALSE)))
# a b
#1: NA NA
#2: 20 FALSE
A.K.
- Original Message -
From: Saptarshi Guha saptarshi.g...@gmail.com
To: R-help@r-project.org R-help@r-project.org
Cc:
Sent: Wednesday, September 18, 2013 6:56 PM
Subject:
I've developed a new graphics library, BDGraphs, designed for big
data, meaning any data large enough to cause major screen clutter and
overplotting if the points are plotted individually.
The library includes a novel approach to parallel coordinates, and some
methods I introduced in my JSM talk
Hello -
I have read about a function, replace.df(), that is available in base R. It
seems ideal since it would allow me to replace specific columns in one data
frame with columns in another data frame, while keeping all other columns
intact. The problem is that replace.df() does not seem to exist
Hello,
This function doesn't exist in any package. I found it using a web search
engine (estimated time, 30sec):
http://stackoverflow.com/questions/7971513/using-one-data-frame-to-update-another
Regards,
Pascal
2013/9/19 Alecia M Moser amos...@binghamton.edu
Hello -
I have read about a
Hello -
I am looking for a function that would allow me to replace specific columns
in one data frame with columns in another data frame using a grouping
variable.
df - read.csv(data.csv, header=T)
df1 - aggregate(df[, c(8,9,10,11,12,27,28)], by=list(df$ID),
FUN=function(x) sub((.*):, \\1., x))
60 matches
Mail list logo