Dear list members,
I would like to measure how much time one function call makes from the time is
call until the time it returns.
Could you please tell me if that is possible in R?
Best Regards
Alex
__
R-help@r-project.org mailing list
This should do it:
boxplot(log(a[,2:52]),main = list.files()[3],col = c(red, green))
Tal
Contact
Details:---
Contact me: tal.gal...@gmail.com | 972-52-7275845
Read me: www.talgalili.com (Hebrew) | www.biostatistics.co.il
There you go:
rdata = replicate(100, rnorm(15)) #construct a 2D matrix
c1 = cor(rdata)
require(reshape)
m_c1 - melt(as.matrix(c1))
head(m_c1)
Cheers,
Tal
Contact
Details:---
Contact me: tal.gal...@gmail.com |
Hi Roark,
From my experience, this error is because of problem with reading the
headers, or problem with the sep parameter in read.table
Try something like
read.table(... ,sep =\t) (This is for tab delimited files)
Others might give more ideas.
Cheers,
Tal
Contact
Hi Ben,
thanks a lot for your answer.
There are four reasonable solutions to your problems:
1. ignore the warnings, as long as they are all of the
same type (NaNs/NAs being produced by dbinom or dpois),
and as long as the final results look sensible.
probably fine for me. The fit for my
On Fri, 2011-01-28 at 10:00 +1100, Dario Strbenac wrote:
Hello,
Yes, that's right, it is a values matrix. Not a dissimilarity matrix.
i.e.
str(iMatrix)
num [1:23371, 1:56] -0.407 0.198 NA -0.133 NA ...
- attr(*, dimnames)=List of 2
..$ : NULL
..$ : chr [1:56] -8100 -7900 -7700
hi,
i am trying to label a plot axis with the equivalent of the latex $n_*$.
i initially tried
expression(paste(italic(n)[*]))
but this made the * absolutely tiny and centred about midway wrt the n.
then
expression(paste(italic(n)[textstyle(*)]))
made the * about the right size but now it
On 01/28/2011 07:57 AM, Greg Snow wrote:
Try:
library(TeachingDemos)
plot(Sepal.Length~Sepal.Width, data=iris)
tmp.y- iris$Sepal.Length
for( i in unique(iris$Sepal.Width) ) {
tmp- iris$Sepal.Width == i
tmp.y[ tmp ]- spread.labs( tmp.y[tmp], .6*strheight('A'),
On Fri, 28 Jan 2011, Andrew Collier wrote:
hi,
i am trying to label a plot axis with the equivalent of the latex $n_*$.
i initially tried
expression(paste(italic(n)[*]))
but this made the * absolutely tiny and centred about midway wrt the n.
then
expression(paste(italic(n)[textstyle(*)]))
Hello,
Thanks to everyone for the multiple answers. Josh, thanks for the
function. My data 12 datasets have over 500,000 rows so your answer
greatly appreciated.
Cheers,
Daisy
On Thu, Jan 27, 2011 at 9:10 PM, Joshua Wiley jwiley.ps...@gmail.com wrote:
Hi,
This problem seemed deceptively
What makes matrix to print V1, V2 as the row and col indices instead of
numbers??
cdata = read.table(ramesh.txt) #cdata is read from a file.
c1 = cor(cdata)
I am printing c1 below. I need only numbers. I dont need V1, V2...what
should I do in this case??
Hi Ben,
thanks a lot for your answer.
There are four reasonable solutions to your problems:
1. ignore the warnings, as long as they are all of the
same type (NaNs/NAs being produced by dbinom or dpois),
and as long as the final results look sensible.
probably fine for me. The fit for my
Can somebody me helfen?
I am confused how to use R to test the data wether it is pawer law
distribution or not .
power.law.fit in R can be used to calculate alpha,but with my knowledge
firstly xmin should be confirmed before testing the data.Aber how? And the
data has some zero values, that
Hi Kevin,
I have the same problem that you encountered , how did you resolved it?
could you help me please?!!!
Mohammad
--
View this message in context:
http://r.789695.n4.nabble.com/Installing-rgl-tp865867p3243992.html
Sent from the R help mailing list archive at Nabble.com.
On 01/28/2011 11:00 AM, Dario Strbenac wrote:
Hello,
I've drawn a black rectangle over the plotting area, and when I add an image()
heatmap, it doesn't take up all the area, but is set inward from the black
rectangle. Can anyone suggest how to make it stretch out to the entire area ?
Minimal
thanks for the rapid response.
yes, in x11 your suggestion works perfectly. i have never thought of the
asterisk as being a superscript... to me it has always been the
mulitply sign which is centred. thanks for the education!
however, my plot is being sent to postscript, which i guess does not
Dear All,
I have Windows Vista and I want to install R. However, when I tried to start
it after the installation, I received the following message:
'Fatal error. I cannot retrieve the saved data from .RData'. So, in the
moment R does not work.
Do you have any idea how to cope with this
I tried to modify the code,thanks for noticing...now i get that the function
cannot be evaluated at initial parameters.However I do not know what does
that mean..Should I try to modify parameters. I am still not sure of syntax
of function. I cannot get that optimize work correctly. I am trying to
Dear all,
I have a question about the output of linear mixed model fitted in R
using nlme package. In particular, what are the t-values that are given
in an output, how are they calculated and based on what test? I guess it
cannot be a simple Student t-test, otherwise how can the simple
On Thu, Jan 27, 2011 at 05:30:15PM +0100, Petr Savicky wrote:
On Thu, Jan 27, 2011 at 11:30:37AM +0100, Serena Corezzola wrote:
Hello everybody!
I?m trying to define the optimal number of surveys to detect the highest
number of species within a monitoring season/session.
[...]
Hi Belle,
try this:
SAS:
proc mixed data=test noclprint noinfo covtest noitprint
method=reml;
class pair grade team school;
model score = trt pair grade school / solution ddfm=bw
notest;
random int / sub=team solution type=un r;
run;
R:
require(nlme)
unstruct -
On Thu, 2011-01-27 at 08:20 -0500, Jason Nelson wrote:
Sorry about re-posting this, it never went out to the mailing list when I
posted this to r-help forum on Nabble and was pending for a few days, now
that I am subscribe to the mailing list I hope that this goes out:
I've been a viewer of
On 28-Jan-11 10:24:23, Andrew Collier wrote:
thanks for the rapid response.
yes, in x11 your suggestion works perfectly. i have never
thought of the asterisk as being a superscript... to me it
has always been the mulitply sign which is centred.
thanks for the education!
however, my plot
On Thu, Jan 20, 2011 at 2:04 PM, E Hofstadler e.hofstad...@gmail.com wrote:
Dear all,
Being a newbie to R, I've trawled through many old posts on this list
looking for a solution to my problem, but unfortunately couldn't quite
figure it out myself. I'd be very grateful if someone here on this
On Thu, 2011-01-27 at 09:50 -0500, Thomas Stewart wrote:
For question 2,
TTT - rt(1000,3)
mean(TTT[rank(TTT) = 975 rank(TTT) 25])
mean(TTT, trim = 0.05)
What you are doing is only removing 5% of observations in total, whilst
the question asks for 5% removed off *each* end.
G
On Thu,
Dear All,
I was wondering why survreg (in survival package) can not handle three-way
interactions. I have an AFT (accelerated failure time) model with a
frailty term. If the model is restricted to two-way interactions, survreg
and gamlss.cens (with random() term) give very similar results,
On Thu, Jan 20, 2011 at 9:45 AM, Max Kuhn mxk...@gmail.com wrote:
Hello everyone,
I'm stumped. I'd like to create a scatterplot matrix with circular
reference lines. Here is an example in 2d:
library(ellipse)
set.seed(1)
dat - matrix(rnorm(300), ncol = 3)
colnames(dat) - c(X1, X2, X3)
Dear All,
I'm generating a heatmap, is there a way to make Y axis name display
horizontally, X axis name display vertically?
I tried using horiz=TRUE:
axis(1,at=1:dim(cor.meta.m)[1],labels=gsub(module,,pw.names),horiz=T
RUE)
but got warning message and the name is not displayed as I wish:
magic! this does the trick:
expression(paste(italic(n)[symbol(\052)]))
thanks for the hint, ted!
--
Andrew B. Collier
Physicist
Waves and Space Plasmas Group
Hermanus Magnetic Observatory
Honorary Senior Lecturer tel: +27 31 2601157
Space Physics Research
On Fri, Jan 21, 2011 at 8:22 PM, Fabrice Tourre fabrice.c...@gmail.com wrote:
Hi list,
I want to plot two plot in the same figure. I set par(new=TRUE). But
it does not work.
library(lattice)
myPanel - function(x,...)
{
panel.histogram(x,alpha=0.4,...)
Gavin Simpson gavin.simp...@ucl.ac.uk
on Fri, 28 Jan 2011 09:23:05 + writes:
On Fri, 2011-01-28 at 10:00 +1100, Dario Strbenac wrote:
Hello,
Yes, that's right, it is a values matrix. Not a dissimilarity matrix.
i.e.
str(iMatrix)
num
On 11-01-28 5:15 AM, Iva wrote:
Dear All,
I have Windows Vista and I want to install R. However, when I tried to start
it after the installation, I received the following message:
'Fatal error. I cannot retrieve the saved data from .RData'. So, in the
moment R does not work.
Do you have any
On Fri, 28 Jan 2011, Duncan Murdoch wrote:
On 11-01-28 5:15 AM, Iva wrote:
Dear All,
I have Windows Vista and I want to install R. However, when I tried to
start
it after the installation, I received the following message:
'Fatal error. I cannot retrieve the saved data from .RData'. So,
On Thu, Jan 27, 2011 at 11:23 PM, H Roark hrbuil...@hotmail.com wrote:
I need to import a large number of simple, space-delimited text files with a
few columns of data each. The one quirk is that some rows are missing data
and some contain junk text at the end of each line. A typical file
Hello Deepayan,
many thanks for your reply and help. Does this solution with
ylab.right require a newer version of lattice (somewhere in the
archives I noted ylab.right being mentioned in the context of a
development version of lattice)?
I currently use R version 2.11.1 (2010-05-31) via Emacs
Gavin,
Thanks for your help, but I did find in Booker et al. 2009 supplemental
material where they did use logLik for quasi- distributed data.
Even though it was for mixed models effect. In section 6 in the
supplemental material, this is the model:
mp1 - lmer(total.fruits ~ nutrient * amd +
Dear Adrian,
I would like to export a quite large matrix from R to Excel (40 columns, 257
597 rows). After 10 minutes of work, I get the following error message:
Error in .jcall(row[[ir]], Lorg/apache/poi/ss/usermodel/Cell;, createCell,
:
Java Exception no description because toString()
Kostenko, Olga O.Kostenko at nioo.knaw.nl writes:
I have a question about the output of linear mixed model fitted in R
using nlme package. In particular, what are the t-values that are given
in an output, how are they calculated and based on what test? I guess it
cannot be a simple Student
In a boxplot - how can I prevent groups where the number of cases is less
than a set threshold from being plotted.
set.seed(42)
DF - data.frame(type=sample(LETTERS[1:5], 100, replace=TRUE),
cost=rnorm(100))
count - boxplot(cost ~ type, data=DF, plot = 0)
count$n
## how to only include
On Fri, Jan 28, 2011 at 5:21 PM, E Hofstadler e.hofstad...@gmail.com wrote:
Hello Deepayan,
many thanks for your reply and help. Does this solution with
ylab.right require a newer version of lattice (somewhere in the
archives I noted ylab.right being mentioned in the context of a
development
Hello list.
I was trying to see some of the code for plot.glmnet in package glmnet (this
function name is in the documentation).
After loading the library, I tried the obvious typing in the name, but I
received a message telling me it could not be found.
So I fiddled around a little, and
On 27.01.2011 19:33, Raquel Rangel de Meireles Guimarães wrote:
Hi all,
I have two basic questions, hope you should help me:
1. How do I save a log file in R with the results? For example, in Stata
it can be done by using log using c:\...\test.txt
See ?sink.
2. How do I display the
(English version below)
Queridos R-usuarios!
Â
Con mis colegas estamos creando un curso básico de nuestra espectacular
herramienta R. Nos hemos dado cuenta que muchas personas usan software
comercial y pensamos que serÃa una buena oportunidad para dar un curso gratis
acerca de R. Por otro
dear Nick,
getAnywhere(plot.glmnet)
Note the message you get when you type
methods(plot)
...
Non-visible functions are asterisked
Il 28/01/2011 14.26, Nick Sabbe ha scritto:
Hello list.
I was trying to see some of the code for plot.glmnet in package glmnet (this
function name is in
On 2011-01-27 20:23, H Roark wrote:
I need to import a large number of simple, space-delimited text files with a
few columns of data each. The one quirk is that some rows are missing data and
some contain junk text at the end of each line. A typical file might look like:
a b c d
1 2 3 x
4 5
Thanks for that, Vito.
Somehow, I often get lost in the whole slew of similar methods:
* get
* getMethod
* showMethods
* getAnywhere
* methods
Does anybody have a simple list of when to use which one?
And maybe I'm even missing some variants?
Thx.
Nick.
-Original Message-
From: Vito
Hi
r-help-boun...@r-project.org napsal dne 28.01.2011 09:52:05:
What makes matrix to print V1, V2 as the row and col indices instead of
numbers??
cdata = read.table(ramesh.txt) #cdata is read from a file.
c1 = cor(cdata)
I am printing c1 below. I need only numbers. I dont need V1,
Hello Petr.
First of all, thank you for your help!
If i understand you correctly, your real table U has 32 rows and you want
to consider all subsets of at most 10 rows.
Sorry, I wasnt clear: I have more datasets to analyse, some of them of just
10 samples, and others of 32.
So:
Dear list,
I've had this a few times now, and wonder if this is possible:
I'm using a package, often for plotting something, but I want to tune the
way the plotting goes, in a way that was not foreseen by the maker of the
package.
Now, most of the time, these kinds of R functions (say
On 28.01.2011 14:21, pdb wrote:
In a boxplot - how can I prevent groups where the number of cases is less
than a set threshold from being plotted.
set.seed(42)
DF- data.frame(type=sample(LETTERS[1:5], 100, replace=TRUE),
cost=rnorm(100))
count- boxplot(cost ~ type, data=DF, plot = 0)
On 28.01.2011 09:07, Alaios wrote:
Dear list members,
I would like to measure how much time one function call makes from the time is
call until the time it returns.
Could you please tell me if that is possible in R?
?system.time
Uwe Ligges
Best Regards
Alex
On 28.01.2011 14:57, Nick Sabbe wrote:
Dear list,
I've had this a few times now, and wonder if this is possible:
I'm using a package, often for plotting something, but I want to tune the
way the plotting goes, in a way that was not foreseen by the maker of the
package.
Now, most of the
Use the argument las as explained in ?par.
Uwe Ligges
On 28.01.2011 11:56, Yan Jiao wrote:
Dear All,
I'm generating a heatmap, is there a way to make Y axis name display
horizontally, X axis name display vertically?
I tried using horiz=TRUE:
On 2011-01-28 06:09, Uwe Ligges wrote:
On 28.01.2011 14:21, pdb wrote:
In a boxplot - how can I prevent groups where the number of cases is less
than a set threshold from being plotted.
set.seed(42)
DF- data.frame(type=sample(LETTERS[1:5], 100, replace=TRUE),
cost=rnorm(100))
count-
On Fri, Jan 28, 2011 at 8:57 AM, Nick Sabbe nick.sa...@ugent.be wrote:
Dear list,
I've had this a few times now, and wonder if this is possible:
I'm using a package, often for plotting something, but I want to tune the
way the plotting goes, in a way that was not foreseen by the maker of
Hello,
I have a data set with each column containing data like this:
row column1
1 1.2
2 NA
3 NA
4 3
5 5
6 NA
7 1.5
8 NA
9 NA
10 NA
11 3
12 NA
13 3
14 NA
15 NA
16 NA
17 NA
18 3
19 1.2
20 NA
From this I would like to extract the sequence containing at least three rows
of 3 in
I was wondering why survreg (in survival package) can not handle
three-way interactions. I have an AFT .
You have given us no data to diagnose your problem. What do you mean
by cannot handle -- does the package print a message no 3 way
interactions, gives wrong answers, your laptop
Begin forwarded message:
From: stephen sefick ssef...@gmail.com
Date: January 28, 2011 9:11:07 AM CST
To: Claudia Paladini claudiapalad...@web.de
Subject: Re: [R] mvoutlier
Try this.
#your code
library(mvoutlier)
library(robustbase)
data(bsstop)
x=bsstop[1:100,5:14]
Hi
r-help-boun...@r-project.org napsal dne 28.01.2011 15:37:07:
Hello,
I have a data set with each column containing data like this:
row column1
1 1.2
2 NA
3 NA
4 3
5 5
6 NA
7 1.5
8 NA
9 NA
10 NA
11 3
12 NA
13 3
14 NA
15 NA
16 NA
17 NA
18 3
19 1.2
20
This looks like homework. We don't do homework. Certainly not when you
obviously haven't a) read the posting guide, b) asked your
professor/tutor, c) googled to see if you find something online, d) at
least made an effort to try, and e) read the posting guide.
Do all the points above and
Dear help, dear John Chambers,
I'm trying to learn OOP-possibilities in R and I was going through the
documentation 'ReferenceClasses {methods}'. (great work, by the way...)
Reading associated Examples, something bothers me : it seems to me that there
are errors in 'edit' and 'undo' methods. I
Hi
KumaraGuru kumaragur...@gmail.com napsal dne 28.01.2011 17:03:50:
I want to melt the cor matrix and form a 3 col matrix with row# col# and
cor.
Well, in that case it will be probably better to transform it to data
frame and use melt. Or you can drop dimensions of this matrix and generate
I am wondering if there's any news about reading ODS files
directly. ODS files are the spreadsheet files produced by
OpenOffice.org. Currently, I export sheets in these files to csv
files, one for each sheet. However, it would be much more
convenient to read them directly. Thanks for hints and
On Jan 28, 2011, at 11:05 AM, Marc Carpentier wrote:
Dear help, dear John Chambers,
I'm trying to learn OOP-possibilities in R and I was going through the
documentation 'ReferenceClasses {methods}'. (great work, by the
way...)
Reading associated Examples, something bothers me : it seems to
On 11-01-28 17:37, Sascha Vieweg wrote:
I am wondering if there's any news about reading ODS files directly. ODS
files are the spreadsheet files produced by OpenOffice.org. Currently, I
export sheets in these files to csv files, one for each sheet. However, it
would be much more convenient to
I want to melt the cor matrix and form a 3 col matrix with row# col# and cor.
This I m using to draw a graph.
Regards,
Kumaraguru
On Jan 28, 2011, at 6:47 AM, Petr PIKAL petr.pi...@precheza.cz wrote:
Hi
r-help-boun...@r-project.org napsal dne 28.01.2011 09:52:05:
What makes matrix
Dear list,
I am looking to plot a line on a graph to show the 1:1 relationship, in order
to demonstrate the pattern i have observed is off the line, however i am
unsure. I have tried abline but i can not see a function to plot the 1:1?
Any help would be greatly appreciated
#generate data
y -
While listing it like that is it possible to remove the rows that has same row
and col numbers?
Like..
1 1 x
2 2 x2
Regards,
Kumaraguru
On Jan 28, 2011, at 9:23 AM, Petr PIKAL petr.pi...@precheza.cz wrote:
Hi
KumaraGuru kumaragur...@gmail.com napsal dne 28.01.2011 17:03:50:
I
Suppose your correlation matrix is called cc. One way
to do what you want is
result = cbind(as.vector(row(cc)),as.vector(col(cc)),as.vector(cc))
result = result[result[,1] != result[,2],]
- Phil Spector
Hello Greg, Kevin, Jim and other R-help members,
Regarding text spacing:
Drew Conway published today a fascinating post about Building a Better Word
Cloud.
I don't know if his function can help you (or if either of you might help
him with his code).
But either way, I think it's worth reading his
Hi,
I'm trying to make a model in order to know wich factors got´s influence in
the intensity of a infection, but just in the individuals who's got this
infection. In my data I've got a variable called prevalence with 2 levels:
1.- Infected individual
0.- Non infected
So what i'm trying to do is
Hi,
I am preparing a quite huge database in Excel, I replaced the empty cells with
NA, I formatted it like text, and saved the file like a *.txt.
After, in R:
data-read.table(myfile.txt,header=T,sep=\t)
edit(data)
When doing this I can see that some columns are OK and they have NA cells, but
Right. Shame on me : Friday's tiredness ; I don't know why I stuck on that.
Please just consider the main topic of my message, regarding the example of
ReferenceClasses (supposing it's appropriate) and sorry for the subsequent
question...
- Message d'origine
De : David Winsemius
abline() takes the intercept and slope, which for a 1:1 relationship
are 0 and 1, respectively.
So:
abline(0, 1)
Sarah
On Fri, Jan 28, 2011 at 10:42 AM, Peter Francis peterfran...@me.com wrote:
Dear list,
I am looking to plot a line on a graph to show the 1:1 relationship, in order
to
On Jan 28, 2011, at 12:35 PM, Marc Carpentier wrote:
Right. Shame on me : Friday's tiredness ; I don't know why I stuck
on that.
Please just consider the main topic of my message, regarding the
example of
ReferenceClasses (supposing it's appropriate) and sorry for the
subsequent
Hi Mario,
On Fri, Jan 28, 2011 at 12:27 PM, gaiarrido gaiarr...@usal.es wrote:
Hi,
I'm trying to make a model in order to know wich factors got´s influence in
the intensity of a infection, but just in the individuals who's got this
infection. In my data I've got a variable called prevalence
Tinn-R (http://www.sciviews.org/Tinn-R/) is one of the topmost
suggestions when googling an R-(text-)editor for Windows. However,
to me it appears dissappointing that Tinn-R does not handle utf-8
(mac-roman, or any other) encoded R-scripts or, in general, text
files. Besides Emacs and the R
I hadn't found any message on this subject.
Nevertheless you're right again : I've posted this report on r-devel-list where
it obviously belongs...
Marc
- Message d'origine
De : David Winsemius dwinsem...@comcast.net
À : Marc Carpentier marc.carpent...@ymail.com
Cc :
Dear All,
It might be a simple question. But I could not find the answer from function
âprcompâ or âprincompâ. Does anyone know what are the codes to get
coefficient and scores of Principal component analysis in R?
Your reply will be appreciated!
Best
Zunqiu
[[alternative
On my first foray into foreach I am getting this error:
Error in function (handle) :
no function to return from, jumping to top level
I get one of these for each worker.
I am using the doMC/multicore back end.
At first I thought this was caused by the text progress bars that the
By coefficients do you mean loadings?
Anyway, if you read the help for princomp -- ?princomp -- will
get that, you'll see that it says, in part:
‘princomp’ returns a list with class ‘princomp’ containing the
following components:
sdev: the standard deviations of the principal
I strongly suggest reconsidering your rejection of Emacs + ESS.
However, if you cannot be persuaded of this, I hear WinEdit is pretty
good.
In case you haven't already found them, the following resources may be helpful:
http://www.sciviews.org/_rgui/projects/Editors.html
Hello
On Fri, Jan 28, 2011 at 8:16 PM, Zunqiu Chen che...@ohsu.edu wrote:
It might be a simple question. But I could not find the answer from function
“prcomp” or “princomp”. Does anyone know what are the codes to get
coefficient and scores of Principal component analysis in R?
Try these:
Hello all
I have the data frame with this:
ID DATETIME TRN TRN_S
1 1192756 2010-06-23 15:39:07 13.420 0.2236667
2 1192757 2010-06-23 15:40:07 13.805 0.2300833
3 1192758 2010-06-23 15:41:07 13.860 0.231
4 1192759 2010-06-23 15:42:07 13.750 0.2291667
5
I'm curious. I've used the paired-prentice Wilcoxon test for the analysis
of parried survival data. I haven't run into use of the coxph for that
previously, but I have seen it referenced a couple of times in recent web
searches.
I have a data set of subjects like this:
SubjectT1 R1 T2
Notepad ++ handles just about anything and has an accompanying program
NppToR to make passing scripts easier.
Geany also handles a ton of filetypes, but lacks a direct interface to R
in the windows version - I wrote an AutoHotKey script that did this for me
in about 5 minutes. On the other
On Jan 28, 2011, at 3:07 PM, Ottar Kvindesland wrote:
Hello all
I have the data frame with this:
ID DATETIME TRN TRN_S
1 1192756 2010-06-23 15:39:07 13.420 0.2236667
2 1192757 2010-06-23 15:40:07 13.805 0.2300833
3 1192758 2010-06-23 15:41:07 13.860
michalseneca michalseneca at gmail.com writes:
I tried to modify the code,thanks for noticing...
now i get that the function cannot be evaluated at initial parameters.
However I do not know what does that mean..
Should I try to modify parameters. I am still not sure of syntax of
function. I
James Meadow jfmeadow at gmail.com writes:
Hi,
I am trying to work with the ape package, and there is one thing I am
struggling with. When calling the *read.GenBank()* function, I can get it
to work with an object created like this:
*x - c(AY395554,AY611035, ...)*
*read.GenBank(x)*
Hi Sascha,
On 01/28/2011 07:55 PM, Sascha Vieweg wrote:
Tinn-R (http://www.sciviews.org/Tinn-R/) is one of the topmost
suggestions when googling an R-(text-)editor for Windows. However, to me
it appears dissappointing that Tinn-R does not handle utf-8 (mac-roman,
or any other) encoded R-scripts
Johannes Huesing johan...@huesing.name [Mon, Jan 10, 2011 at 09:26:37PM CET]:
I am trying to model survival data with a Weibull distribution
using survreg. Units are clustered two apiece, sometimes receiving
The fire devoured my laptop, but the PC is still working... :)
Sorry for the lazyness, you are totally right.
Here goes a reproducible example, which resembles the main features of our
dataset:
# three experimental factors, 30 subjects
expgrid - expand.grid(F1=0:1,F2=0:1,F3=0:1,id=1:30)
# set
I want to predict values from an existing lm (linear model, e.g.
lm.obj) result in R using a new set of predictor variables (e.g.
newdata). However, it seems that because my linear models was made by
calling scale() on the target predictor that predict exits with an
error, Error in scale(xxA,
Greetings
Though I have months in chronological order in my data table, the data
were sampled every other month (i.e., February, April, June, August,
October, December), every time I try to plot them (on the x-axis) they are
plotted in alphabetical order. What am I missing?
Cheers
Kurt
Kurt
You need to give us more information if you want good advice. For example,
what sort of plot are you trying to make?
A barplot? A time series?
A reproducible example is always best. Please see the R-news posting guide for
hints on a successful query.
On Jan 28, 2011, at 1:53 PM,
On Jan 28, 2011, at 4:53 PM, kurt_h...@nps.gov wrote:
Greetings
Though I have months in chronological order in my data table,
the data
were sampled every other month (i.e., February, April, June, August,
October, December), every time I try to plot them (on the x-axis)
they are
You need to make your variable into a factor and specify the order.
mymonths - c(December, March)
factor(mymonths)
[1] December March
Levels: December March
factor(mymonths, levels=month.name)
[1] December March
12 Levels: January February March April May June July August September
October ...
In addition you may want to include asp=1 and pty='s' to the plot command.
--
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.s...@imail.org
801.408.8111
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-bounces@r-
project.org]
This would be easier if you showed us a sample of your data and what commands
you are using. Without we need to guess.
Probably your month variable is being turned into a factor somewhere and the
default for factors is alphabetical. The best solution depends on
how/where/when your months are
Hi Russell,
There may be some subtleties that I'm not picking up on, but the
obvious problem is that the names of the predictors in newdata do not
match the names of the predictors in dat.
names(newdata) - names(dat)[1:2]
newdata$Y - predict(lm.obj,newdata)
does work on my machine.
Best,
1 - 100 of 115 matches
Mail list logo