Dear R People:
Here is something that I am sure is very simple. I'm just trying to
re-create the C convolution example in the Extensions manual. Here is
the subroutine:
void convolve(double *a, int *na, double *b, int *nb, double *ab)
{
R_len_t i, j, nab = *na + *nb - 1;
for(i = 0; i nab;
G'day Erin,
On Thu, 15 Mar 2012 01:03:59 -0500
Erin Hodgess erinm.hodg...@gmail.com wrote:
What is wrong, please?
Missing
#include R.h
#include Rinternals.h
In particular the latter is defining R_len_t. Guess that code snippet
in the manual is only showing the code of the function, but not
Hi Erin,
If you are just starting with including compiled code, I would highly
recommend the Rcpp + inline packages. I attached a small example of
how it works, but basically you get to inline C++ code in R files.
Cheers,
Josh
P.S. I wrote this snippet awhile ago when I did not know much
Do you really expect is to know how to figure out the error if you don't give
us the code that the error is pointing at (or the code preceding the error,
which may be at fault)? Please think before posting.
---
Jeff
Seems you're missing the required header(s). Can't find the example in
the extensions manual but you probably need
#include Rinternals.h
or
#include Rdefines.h
HTH,
Peter
On Wed, Mar 14, 2012 at 11:03 PM, Erin Hodgess erinm.hodg...@gmail.com wrote:
Dear R People:
Here is something that I
Dear all,
I would like at the beginning of my code to turn off all the remaining open
devices.
How can I do that by using dev.off()?
I would like to thank you in advance for your help
B.R
Alex
[[alternative HTML version deleted]]
__
On Wed, Mar 14, 2012 at 09:10:49PM -0400, Axel Urbiz wrote:
I'll appreciate your help on this. I have values stored in a list as in
mylist below. I need to sum the values over all elements of the list
aggregated by the names of the matrices.
mylist - list(matrix(c(0.2, 0.4), 1, 2, dimnames =
Hi,
Try this,
replicate(sample(10,1), dev.new())
graphics.off()
HTH,
baptiste
On 15 March 2012 20:36, Alaios ala...@yahoo.com wrote:
Dear all,
I would like at the beginning of my code to turn off all the remaining open
devices.
How can I do that by using dev.off()?
I would like to
On 15/03/2012 07:36, Alaios wrote:
Dear all,
I would like at the beginning of my code to turn off all the remaining open
devices.
How can I do that by using dev.off()?
See the help page.
Hint: there is a function graphics.off() on the same page.
I would like to thank you in advance for
On Wed, 14-Mar-2012 at 11:39PM +0100, Tomáš Křehlík wrote:
| Hello R people
|
[...]
| The best documentation that I ever used is probably one of
| Mathematica, look for example here
| http://reference.wolfram.com/mathematica/ref/Fit.html (it is
| somehow related to the stuff below).
[...]
Hi
Dear all I am having a vector with large length and I would like to ask
you if I can aggregate the values by constant sized windows. For example
for the following vector, I would like to take 30 points until the end
and find their mean.
myData-seq(1:10)
Hi All
I would like to compute the raw p-value from permutation tests and I found
mt.sample.rawp() from the package multtest almost similar to what I want to
do. But in the function definition:
mt.sample.rawp(V,classlabel,test=t,side=abs,fixed.seed.sampling=y,B=1,na=.mt.naNUM,nonpara=n)
I'm trying to figure out if it's possible to use a character string as an
equation, e.g:
eqn1string - x^2 + x + 5
Then I want to tell R:
1) that eqn1string is actually an equation (even though it was stored as a
character string), and
2) to apply the equation to a specified value of x (e.g.
Hi everyone,
I need to see the source code of function
Does anybody know how can I find so.
Thanks a lot.
--
View this message in context:
http://r.789695.n4.nabble.com/Source-code-tp4474173p4474173.html
Sent from the R help mailing list archive at Nabble.com.
I am trying to use rEMM package for the Extensible Markov Models. I tried the
following sequence of code:
emmt=EMM(measure=euclidean,threshold=0.75,lambda=0.001)
emmt=build(emmt,data)
new_threshold=sum(cluster_counts(emmt))*0.002
emmt_ new=prune(emmt,new_threshold)
However, I get the following
Hi Emily,
Yes (see below), but you might be better off by writing a simple
function. Here are examples both ways (usually eval parse is highly
discouraged).
Cheers,
Josh
#
eqn1string - x^2 + x + 5
x - 6
## works
eval(parse(text = eqn1string))
## better
f - function(x)
Hi all,
I want to create a new list with names of another list. Eeach sublist from
both lists is a matrix, but the matrices with the same name (eg. list.1
[[1]] and list.2 [[1]]) have different dimensions. How can I create the 2nd
list?
tSE = list ()
Norm - names(Normal)
names(tSE) - Norm
2012/3/14 Tomáš Křehlík tomas.kreh...@gmail.com:
Hello R people
I get the feeling (by some experience with learning programming languages
when I am not primarily a programmer but economist/statistician) that
structure of help really helps and I would like to have it to go in the way
basic
Hi
Hi everyone,
I need to see the source code of function
Does anybody know how can I find so.
Thanks a lot.
What function?
mean.default
function (x, trim = 0, na.rm = FALSE, ...)
{
if (!is.numeric(x) !is.complex(x) !is.logical(x)) {
warning(argument is not numeric or
Hi,
function is a primitive, so seeing its source will take some work.
See page 43 of http://cran.r-project.org/doc/Rnews/Rnews_2006-4.pdf
for a guide on viewing compiled code sources.
Cheers,
Josh
On Thu, Mar 15, 2012 at 1:05 AM, AnaKar lupasa...@gmail.com wrote:
Hi everyone,
I need to see
On Thu, Mar 15, 2012 at 01:44:10AM -0700, ali_protocol wrote:
Hi all,
I want to create a new list with names of another list. Eeach sublist from
both lists is a matrix, but the matrices with the same name (eg. list.1
[[1]] and list.2 [[1]]) have different dimensions. How can I create the
Dear R users,
first I take this opportunity to greet all the R community for your
continuous efforts.
I wrote a function to calculate the pdf and cdf of a custom distribution
(mixed gamma model).
The function is the following:
pmixedgamma3 - function(y, shape1, rate1, shape2, rate2, prev)
On 14-03-2012, at 23:39, Tomáš Křehlík wrote:
Hello R people
I always wander what other people say about the R help. Finally after some
years of using, I decided that it is probably time to try to do something
about it, because the feeling of gritting teeth does not go away with years
Dear Ilai,
Thank you for your helpfulresponse. My question had two parts.
1. Are mosaic plots a good way to visualise multiple response data? Or are
there better alternatives?
2. How can I do my modified chi-square tests in R (which you were able
answer, so thank you very much :) )
All the
Hi,
On Mar 15, 2012 4:28 AM, Aparna Sampath aparna.sampat...@gmail.com
wrote:
Hi All
I would like to compute the raw p-value from permutation tests and I found
mt.sample.rawp() from the package multtest almost similar to what I want
to
do. But in the function definition:
I am a PhD student working on global scale. I am working at INRA in France.I
am new to R
I downloaded a netcdf file cruncep_tair_2010.nc.gz from
http://dods.extra.cea.fr/data/p529viov/cruncep/t2m/
in this file, temperature was measured every 6 hours for 2010, I want to
convert to
Hi list members,
I have a question about application of Metropolis-Hastings (MH) algorithm
in R. It is said that using this kind of algorithm (MCMC), one can
integrate any complexe function. Is it true ? And how can I proceed with a
whole new one function, which does not include any obvious
i have
x
[1] 1 2 3 4 5 6
y
[1] 34 5 6
z-cbind(x,y)
z
x y
[1,] 1 34
[2,] 2 5
[3,] 3 6
[4,] 4 34
[5,] 5 5
[6,] 6 6
i don't want recycling, instead can we put NA /0 like below z
x y
[1,] 1 34
[2,] 2 5
[3,] 3 6
[4,] 4 NA
[5,] 5 NA
[6,] 6 NA
want distance matrix
--
View
Dear all,
What test should be done on ~40 samples (matrixes of 400x1), each in
triplicate, to determine which sample is the most different to all samples?
and What test should be done to determine the two samples which are most
different?
--
View this message in context:
hi,
what I want to do is assigning following code to any object.
k-paste(thank)
writeLines(strwrap(k, width = 80,indent = 7,exdent = 6))
To assign the writeLines code,
I try this
a-writeLines(strwrap(k, width = 80,indent = 7,exdent = 6))
or
assign(a,writeLines(strwrap(k, width = 80,indent =
Hello
I have this little dataset, my goal is create one column in the
data.frame with between the diference DataTime and Duration.
I'm using the next code to make do this
TIME_STAMP SESSIONTIMETime TimeStart
1162343932 83202006-10-31 19:01:34
You want lme(logSSP~logM + K,random=~logM + K|species,data=data1)
Best regards,
ir. Thierry Onkelinx
Instituut voor natuur- en bosonderzoek / Research Institute for Nature and
Forest
team Biometrie Kwaliteitszorg / team Biometrics Quality Assurance
Kliniekstraat 25
1070 Anderlecht
Belgium
+
Hello can anyone help,
I have been running the following script to obtain a PCA plot but the end
result is rather disappointing as the points are very very small and there are
no titles etc
geochemdata-read.csv(file.choose(),header=TRUE)
names(geochemdata)
library(vegan)
bstick-function(n,
Hello
I have this code for the count the occurrences between V_source and
V_destine, its can possible make the same, but in local the total the
occurrences to appear the mean or the minimum
Dataset
df.v_source df.v_destine df.dif
1 33 4
2 7
On 15-03-2012, at 10:08, sagarnikam123 wrote:
i have
x
[1] 1 2 3 4 5 6
y
[1] 34 5 6
z-cbind(x,y)
z
x y
[1,] 1 34
[2,] 2 5
[3,] 3 6
[4,] 4 34
[5,] 5 5
[6,] 6 6
i don't want recycling, instead can we put NA /0 like below z
x y
[1,] 1 34
[2,] 2 5
[3,] 3 6
Hello R-users,
I have the following question, for which my search did not really return any
usable result.
If I have a matrix a1, and a vector a2 like below
a1-matrix(c(1:4),2,2)
a2-c(8,9)
is there any function like the expand.grid (or some clever calling of the
function) such that it
I find plogis() is easier to remember
all.equal(binomial()$linkinv(seq(-2, 2, length = 101)), plogis(seq(-2, 2,
length = 101)))
ir. Thierry Onkelinx
Instituut voor natuur- en bosonderzoek / Research Institute for Nature and
Forest
team Biometrie Kwaliteitszorg / team Biometrics Quality
use POSIXct instead
Sent from my iPad
On Mar 15, 2012, at 6:21, MSousa ricardosousa2...@clix.pt wrote:
Hello
I have this little dataset, my goal is create one column in the
data.frame with between the diference DataTime and Duration.
I'm using the next code to make do this
On 12-03-14 11:58 PM, casperyc wrote:
Hi all,
Sorry if I seem a bit pissed because I am!
I'd recommend calming down, and explaining the problem clearly. You
tell us about the research you did, but you don't say:
1. What exactly did you do?
2. What was the result?
Without those two
I believe the difficulty is that the integrate function isn't
vectorized: add this line and you should be good
pmixedgamma3 - Vectorize(pmixedgamma3)
Read ? Vectorize for details if you only need to vectorize certain arguments.
Michael
On Thu, Mar 15, 2012 at 6:08 AM, Mauro Rossi
On Thu, Mar 15, 2012 at 5:08 AM, sagarnikam123 sagarnikam...@gmail.com wrote:
i have
x
[1] 1 2 3 4 5 6
y
[1] 34 5 6
z-cbind(x,y)
z
x y
[1,] 1 34
[2,] 2 5
[3,] 3 6
[4,] 4 34
[5,] 5 5
[6,] 6 6
i don't want recycling, instead can we put NA /0 like below z
x y
[1,] 1
I'm not sure what writeLines is for here(); just a - strwrap(k, width
= 80, indent = 7, exdent = 6) if I understand you correctly.
cat(a, \n)
Michael
On Thu, Mar 15, 2012 at 5:13 AM, mrzung mrzun...@gmail.com wrote:
hi,
what I want to do is assigning following code to any object.
Hi Amen:
On Mar 15, 2012, at 2:19 AM, Amen wrote:
I am a PhD student working on global scale. I am working at INRA in France.I
am new to R
I downloaded a netcdf file cruncep_tair_2010.nc.gz from
http://dods.extra.cea.fr/data/p529viov/cruncep/t2m/
in this file, temperature
On 12-03-14 6:39 PM, Tomáš Křehlík wrote:
Hello R people
I always wander what other people say about the R help. Finally after some
years of using, I decided that it is probably time to try to do something about
it, because the feeling of gritting teeth does not go away with years of usage.
Hi
Hello
I have this code for the count the occurrences between V_source and
V_destine, its can possible make the same, but in local the total the
occurrences to appear the mean or the minimum
Your question is rather cryptic and I am rather confused what you really
want.
For row/column
One possibility is to use something like the following:
a1 - matrix(1:4, 2, 2)
a2 - c(8, 9)
cbind(a1[rep(1:nrow(a1), length(a2)), ], rep(a2, each = nrow(a1)))
I hope it helps.
Best,
Dimitris
On 3/15/2012 1:33 PM, eugen pircalabelu wrote:
Hello R-users,
I have the following question, for
Another alternative:
http://research.stowers-institute.org/efg/R/Color/Chart/ColorChart.pdf
http://research.stowers-institute.org/efg/R/Color/Chart/
Best regards,
Henrik
hi everyone .
Now I want to draw several lines in one frame.And it seems needs more
colors except for blue red,black
On Mar 15, 2012, at 6:08 AM, Mauro Rossi wrote:
Dear R users,
first I take this opportunity to greet all the R community for
your continuous efforts.
I wrote a function to calculate the pdf and cdf of a custom
distribution (mixed gamma model).
The function is the following:
Thanks for the point in the right direction. I now have a great solution.
library(GenomicRanges)
system.time({
+ snplist-with(snp, GRanges(CHR, IRanges(POS, POS)))
+ locations-with(targets, GRanges(CHR, IRanges(START, STOP)))
+ olaps-findOverlaps(snplist, locations)
+ })
user system
Dear all,
I have data in the following format :
X-axisY-axis
010%
0-20 20%
20-4030%
40-6040%
. and so on.
I want to plot a bar graph of the above. Also I would want to add a
trendline passing either through the
hi ,I am trying to using wavelet package.
require(wavelets)
wt - dwt(aa, n.levels=4, boundary=reflection, fast=TRUE)
plot(wt)
and we can get the figure as the attachment.
aa is a data array that came from the one day obvervation in 1HZ and has
the length of 86400 .
Can anyone tell me what is
Hi,
I made a mistake, effectively Pascal your method given to the first message
is correct. I didn't use the good data, so it's sure that it could not work
!
But, I have an another question : Can I obtain a same graph except that the
y-axis represents the likelihood ratio ?
All the best,
Sorry, I ll explain better.
For example in the next dataset,
x-data.frame(v_source=3,v_destine=3,dist=4)
x-rbind(x,data.frame(v_source=7,v_destine=7,dist=0))
x-rbind(x,data.frame(v_source=6,v_destine=6,dist=0))
x-rbind(x,data.frame(v_source=4,v_destine=4,dist=56))
Hello there,
I was wondering if anyone might be able to help me as I'm pretty new to R.
I'm trying to create a boxplot from a data table returned from an sproc. I
have the following code, which generates the plot as I'd like it:
library(RODBC);
conn - odbcConnect(datawarehouse); # connect to
Hi All,
I am using the glmer function to adjust a simple model (mod1) with Poisson
response variable and random intercept. When I use logLik(mod1) I obtain a
value different from if I calculate the log-likelihood using the pdf.
Someone could explain if I have an error?
This is the code for the
I obtain this message:
Error: C stack usage is too close to the limit
Marc Marí-Dell'Olmo
CIBER Epidemiología y Salud Pública
Servei de Sistemes d'Informació Sanitària (SeSIS)
Agència de Salut Pública de Barcelona
Pl. Lesseps 1. 08023 Barcelona
Tel. 93 2027775 | Fax. 93 3686943
www.aspb.cat
hi
I'm making some program and it need to be hidden.
it's not commercial purpose but it is educational,
so i do want to hide the code of function.
for example,
if i made following function:
a-function(x){
y-x^2
print(y)
}
i do not want someone to type a and take the code of the function.
Sorry, I ll explain better.
For example in the next dataset,
x-data.frame(v_source=3,v_destine=3,dist=4)
x-rbind(x,data.frame(v_source=7,v_destine=7,dist=0))
x-rbind(x,data.frame(v_source=6,v_destine=6,dist=0))
x-rbind(x,data.frame(v_source=4,v_destine=4,dist=56))
Hi,
I use R to plot a graph with 2 frames. Because the limit of pixel
or others, the screen fail to show the graph. So I have to draw a
point every 10 frames. So the total of x axis becomes 2000.
So when imaging the picture, I still hope that the total of x-axis is
2. I need to find a
On Mar 15, 2012, at 10:23 AM, MSousa wrote:
Sorry, I ll explain better.
For example in the next dataset,
x-data.frame(v_source=3,v_destine=3,dist=4)
x-rbind(x,data.frame(v_source=7,v_destine=7,dist=0))
x-rbind(x,data.frame(v_source=6,v_destine=6,dist=0))
Sorry. I am still using the 9-11 March 2011 version of course2.pdf.
On Wed, Mar 14, 2012 at 5:52 PM, David Winsemius dwinsem...@comcast.netwrote:
On Mar 14, 2012, at 4:09 PM, John Smith wrote:
With most current version of R and RMS, the 4 curves are drew in
4 separate panels. Can anyone
On 15/03/2012 8:53 AM, mrzung wrote:
hi
I'm making some program and it need to be hidden.
it's not commercial purpose but it is educational,
so i do want to hide the code of function.
for example,
if i made following function:
a-function(x){
y-x^2
print(y)
}
i do not want someone to type
Dear all,
I am confused about how to create an expression. I use a package (rsbml)
which uses expressions and seems to make a difference if there is a quote
around the expression or not.
For example, package works with expressions such as
expression(A + B)
but not with
expression(A + B)
I
Hi,
I would like to create some S4 classes as follows
setClass(Father,representation(name=character))
setClass(Son1,contains=Father,representation(par=numeric))
setClass(Son2,contains=Father,representation(par=logical))
Son1-new(Son1)
Son1@name-Son1
Son1@par-3
Son2-new(Son2)
Son2@name-Son2
My colleague asked me to thank those of you who responded.
Kind regards,
Sean
--
View this message in context:
http://r.789695.n4.nabble.com/Moore-Penrose-Generalized-determinant-tp4471629p4475415.html
Sent from the R help mailing list archive at Nabble.com.
Hi,
You didn't copy the main r-help list on this email, so I've added them back it.
Beyond that, I don't see anything grossly wrong. You don't provide
enough information to reproduce the problem: mantel.test() works with
the 7x7 parts you provided.
So you'll need to provide a small reproducible
Hi,
You don't provide a reproducible example, but I suspect what you need is
parse():
parse(text = A + B)
expression(A + B)
Sarah
On Thu, Mar 15, 2012 at 10:55 AM, capy_bara hettl...@few.vu.nl wrote:
Dear all,
I am confused about how to create an expression. I use a package (rsbml)
which
You want to assign your call to boxplot as an object that contains the
plot information
set.seed(1)
b - matrix(rgamma(100,(1:4)/2,.5),nc=4)
(bxp - boxplot(b))
Now you can use the info in bxp for placement, e.g.:
text(1:length(bxp$names),bxp$stats[3,],round(bxp$stats[3,],2),pos=3)
By the way,
On Mar 15, 2012, at 10:55 AM, capy_bara wrote:
Dear all,
I am confused about how to create an expression. I use a package
(rsbml)
which uses expressions and seems to make a difference if there is a
quote
around the expression or not.
For example, package works with expressions such as
Many thanks,
parse is exactly what I was looking for!!
Hannes
--
View this message in context:
http://r.789695.n4.nabble.com/single-double-or-no-quotes-in-expression-tp4475247p4475475.html
Sent from the R help mailing list archive at Nabble.com.
__
Hello,
When plotting a barchart with ggplot it drops the levels of the factor for
which no counts are available.
For example:
library(ggplot)
mtcars$cyl-factor(mtcars$cyl)
ggplot(mtcars[!mtcars$cyl==4,], aes(cyl))+geom_bar()
levels(mtcars[!mtcars$cyl==4,])
This shows my problem. Because no
Sorry - I suspect this is a very basic query.
I have a data frame structured flat (i.e. separate observations for a given
subject ID on separate lines). Using the nlme library I create a groupedData
object suitable for further analysis thus:
dataset - groupedData(VARIABLE ~ TIME|ID, data=sfa)
Great. Thanks very much for that... and for pointing out the obvious error!
Much appreciated.
Tom
--
View this message in context:
http://r.789695.n4.nabble.com/Adding-mean-values-to-boxplots-tp4474700p4475472.html
Sent from the R help mailing list archive at Nabble.com.
Thank you.
Works perfectly
--
View this message in context:
http://r.789695.n4.nabble.com/Average-row-and-column-tp4474524p4475438.html
Sent from the R help mailing list archive at Nabble.com.
__
R-help@r-project.org mailing list
One possibility: update to ggplot2. The original ggplot isn't even on
CRAN any longer.
When I tried your example with ggplot2, the empty bar for 4 was
plotted as you'd expect.
Thanks for the small reproducible example.
Sarah
On Thu, Mar 15, 2012 at 11:47 AM, Bart6114 bartsmeet...@gmail.com
Hi, okay thanks. I've attempted the commands you suggested (I have provided all
of the dput results - I am not sure how to provide a smaller example). I hope
this is ok.
sessionInfo()
R version 2.14.2 (2012-02-29)
Platform: i386-pc-mingw32/i386 (32-bit)
locale:
[1] LC_COLLATE=English_United
Hi Alexander --
On 03/15/2012 07:57 AM, Alexander wrote:
Hi,
I would like to create some S4 classes as follows
setClass(Father,representation(name=character))
setClass(Son1,contains=Father,representation(par=numeric))
setClass(Son2,contains=Father,representation(par=logical))
Son1-new(Son1)
My IS people insist that the latest version of R avaialble via apt-get is
2.13.1. Anything later they claim will have to be compiled. True?
Will I have to compile every time I update R? Seems like a lot of work.
Surely there's a way around it.
- Original Message -
From: Jeff Newmiller
Hi Dorothea,
I've copied the ape maintainer on this, because I believe you may have
found a bug.
Your analysis works without warning in ape 2.8, but gives warnings in
the current ape_3.0.1.
But what makes me think that this is a problem with the new version is
that the example given in
On Wed, Mar 14, 2012 at 9:47 PM, Alex Miller alexjcmil...@gmail.com wrote:
Dear R Users,
I am trying to plot a matrix (a Digital Elevation Model) using wireframe
[lattice] and color that matrix based on a separate/independent matrix of
the same resolution
This makes no sense. the values in
Try this:
Go to your favorite CRAN mirror.
Click on R Binaries then linux then ubuntu and send the link
with directions to install current ubuntu binaries to your IS people.
Which, you'll note, is exactly what Jeff Newmiller suggested.
Sarah
On Thu, Mar 15, 2012 at 12:50 PM, Scott Raynaud
How to add grid lines at specific position to a plot?
Hi all,
[Disclaimer: I have done extensive and intensive searching on Google and
asked around but couldn't find a solution to this problem.
Please help me instead of just pointing out how simple and stupid my
question is. God bless good
Hello,
Hi Emily,
Yes (see below), but you might be better off by writing a simple
function. Here are examples both ways (usually eval parse is highly
discouraged).
Cheers,
Josh
Yes, eval/parse is discouraged but there's a way of using it,
that is less troublesome, to create a
Dear R users,
I have problems handling missing values. THe problem is that after running my
codes the result I get just skips the missing values. What I want is for the
missing values to appear in my results as well. I have put a workable example
below and as you could see the missing value
Hi Martin,
thanks for your quick answer. I didn't know that '.' could be missleading.
Is there any standard way to name function for S4 objects? get,set
etc..?
I saw your example, and I was wondering, why get.par(ext) put out Son1,
and not the same as get.par(new(Son1, name=Son1, par=3))
If I
abline(h=0)
On Thu, Mar 15, 2012 at 1:05 PM, Michael comtech@gmail.com wrote:
How to add grid lines at specific position to a plot?
Hi all,
[Disclaimer: I have done extensive and intensive searching on Google and
asked around but couldn't find a solution to this problem.
Please help me
abline(h = 0) will do what you want. abline(h = c(0,1,2)) would draw
additional lines at y = 1 and y = 2. abline(v = 0) would draw a vertical
line at x = 0. All of these lines will be plotted on top of whatever you
plotted previously, so you may have to replot your points or lines so that
they're
On Thu, Mar 15, 2012 at 12:58 PM, Rui Barradas rui1...@sapo.pt wrote:
Hello,
Hi Emily,
Yes (see below), but you might be better off by writing a simple
function. Here are examples both ways (usually eval parse is highly
discouraged).
Cheers,
Josh
Yes, eval/parse is discouraged but
On 03/15/2012 09:51 AM, Alexander wrote:
Hi Martin,
thanks for your quick answer. I didn't know that '.' could be missleading.
Is there any standard way to name function for S4 objects? get,set
etc..?
Hi Alexander -- it's usually better to include the original email in the
reply, to provide
Hello,
What I want to do with each iteration of the loop I want to create another
uniquely named
groupedData object - I just don't know how to assign a unique variable
name.
The best way should be to create a list of groupedData objects. Along the
lines of
library(nlme)
n - 100
df1 -
Hi everyone.
Based on a dependent variable (y), I'm trying to generate some independent
variables with a specified correlation. For this there's no problems.
However, I would like that have all my regressors to be orthogonal (i.e.
no correlation among them.
For example,
y = x1 + x2 + x3 where
Hello,
I am performing cross-validation on a number of survival models fitted with the
coxph function and would like to use the likelihood ratio test on the left-out
cases as the criteria for comparison of PCA, SPCA, ridge, lasso, etc. Is there
an easy way to do this? I think predict.coxph
Thanks for the fast reply.
I'm using ggplot2 (it was a typo in my code example). However, using exactly
the same example as I mentioned before, it only shows the bars for cyl=68.
How can the behaviour be different on differing machines? I just checked for
updates and I have the latest ggplot2.
Hello,
However, I would like that have all my regressors to be orthogonal (i.e.
no correlation among them.
?poly
poly(cbind(x1, x2, x3), degree=1)
Hope this helps,
Rui Barradas
--
View this message in context:
Dear R experts,
I am trying to import some data from some Excle files into R. My Excle file
contains about 50 sheets.
One solution I can think about is to convert my Excle file into csv file
first and then load data into R using 'read.csv'.
But it seems to me that 'read.csv' only supports
I don't use xlsReadWrite, but I've found XLConnect rather handy for
things like this: once you're going, you can just loop over all sheets
like so:
do.call(rbind, lapply(1:50, function(n) readWorksheet(wb, sheet = n,
OtherArgumentsGoHere)))
which will gather them all in a list (from lapply) and
Beltrand was also on the mark, suggesting you add Michael Rutter's ppa to
your repository sources.
In both cases (adding the CRAN Ubuntu repositories or Michael Rutter's
ppa), an additional package repository is added to your system's packages.
apt then checks that repository along with the
Try adding na.action = na.exclude to your call to gam.
Michael
On Thu, Mar 15, 2012 at 1:00 PM, Mintewab Bezabih
mintewab.beza...@economics.gu.se wrote:
Dear R users,
I have problems handling missing values. THe problem is that after running my
codes the result I get just skips the missing
Hi there.
This is not really working. Here what I have for the moment.
library(ecodist)
x - 1:100
y1 - corgen(x=x, r=.85, epsilon=.01)$y
y2 - corgen(x=x, r=.5, epsilon=.01)$y
y3 - corgen(x=x, r=.25, epsilon=.01)$y
a = poly(cbind(y1, y2, y3), degree=1)
cor(a[,1], a[,2])
In that case, the
The line I gave you will read them in, store them in an object called
a list (which is just a generic holding structure, like a struct in C
or a list in Python) and, once it's got them all in one list, rbind
the whole list together to make one super-data.frame. If you want to
keep them separately,
1 - 100 of 147 matches
Mail list logo