Hi Mark,
What I always do is to produce a prediction data set and use
pv - predict(model, newdata = pdata, se = TRUE)
This is pretty straightforward. You just build the data set like
pdata - with(oldData,
expand.grid(group = levels(group), value = mean(value))
You probably need
Gundala Viswanath wrote:
Hi,
How can I change the back quoted strings below
print(x)
[1] foo
[1] bar
into
[1]`foo`
[2]`bar`
Because later I want to access a named list
with this string:
mylist$`foo`
mylist$`bar`
I can't do it with:
mylist$foo
mylist$bar
In fact you want to use
What are use() and des()? Please note the footer of this message.
(Are you using package epicalc without telling us?)
I suspect that foreign::read.dta is being used. That has argument
'convert.dates', and you could try setting it to FALSE, as the message is
from as.Date.character()
Dear all,
I write you to ask you a suggestion about increasing memory in R. I
use a pc with ram of 4gb, and I put in the link of R the following
statementes, --max-memory.size=2074M and --max-vsize==500M, as I red
in many faq concerning this topic. However, when I run some
regression, the program
Take a look at packages pixmap and rimage ... and read.picture() in package
SoPhy for reading tiff images.
Currently there seems to be no way of reading in png files directly, so they
need to be converted first.
Kenn
On Wed, Aug 6, 2008 at 11:47 AM, Tomas Lanczos [EMAIL PROTECTED] wrote:
Paul Chatfield wrote:
Hi - someone has just e-mailed me direct with the answer which it'd be
helpful to paste just so future users who have the same issue can see. Just
follow the advice below and it works perfectly.
Open a command window (Run;cmd) and cd to the bin directory of your R
There a several pure R packages available like EBImage,pixmap,rimage and
rgdal (reads images
from which you can extract the different bands).
I also offer a software which combines ImageJ and R and is capable to
transfer images to R and create
images from R easily by means of the Rserve
Dear Mark,
The effects package (see the JSS article at
http://www.jstatsoft.org/v08/i15/paper) will probably do what you want.
I hope this helps,
John
--
John Fox, Professor
Department of Sociology
McMaster University
Hamilton, Ontario, Canada
web:
Dear All,
I am currently working with the coxph function within the package survival.
I have the model h_ij = h_0(t) exp(b1x1 + b2x2) where the indicator
variables
are as follows:
x1 x2
VPS 0 0
LTG 1 0
TPM 0 1
[[alternative HTML version deleted]]
Dear Sir
I am very new user of R project. Sir I am a research scholar. I am doing work
on fitting distributions. Sir in using MASS package I am facing the following
errors for my data.
fitdistr(urban$x, gamma)Error in fitdistr(urban$x, gamma) : 'x' must be a
non-empty numeric vector
Dear Prof Brian,
It is true that i used the epicalc package. The functions use() and
des() are from epicalc.
The problem does not occur if i use library(foreign) : tmp -
read.dta(maltreat.dta, convert.dates=FALSE)
sessionInfo()
R version 2.7.1 (2008-06-23)
i386-pc-mingw32
locale:
(Sorry, my last email appeared to be missing the important bits so I'll try
again!)
Dear All,
I am currently working with the coxph function within the package survival.
I have the model h_ij = h_0(t) exp( b1x1 + b 2x2) where the indicator
variables are as follows:
x1 x2
A00
B
Dear all,
I am grateful if anyone provides a solution to my problem of no y-axis
label using png on linux. If I use postscript device or X11 device, it
is fine. On Windows, it works with png. I have tried different versions
of R and none of them works.
Best regards,
Xiaoming Cai, Dr.
School of
Hi,
what does your R-prompt show when you just type:
urban$x
and hit ENTER.
The error message suggests that urban$x does not contain any numeric
elements. So either it is empty or it contains, for example, a factor-coded
(dummy-like) variable.
We will probably need more information to help
Also note there is a program, Rversions.hta, whose
home page is at:
http://batchfiles.googlecode.com
that will list in a drop down menu all versions of R you have installed,
based on the registry information that RSetReg.exe or the R installer sets,
allowing you to select which one you wish to
See if using bitmap() in place of png() works.
On Wed, Aug 6, 2008 at 8:19 AM, Xiaoming Cai [EMAIL PROTECTED] wrote:
Dear all,
I am grateful if anyone provides a solution to my problem of no y-axis
label using png on linux. If I use postscript device or X11 device, it
is fine. On Windows,
Hallo,
i am trying to use the mlogit package (which uses the multinom package
according to the documentation)
the multinom function works fine:
fsex = multinom(country ~ sex, data=included_s_sex_MF)
# weights: 66 (42 variable)
initial value 8222.172926
iter 10 value 7647.481298
iter 20
Is there a likelihod function for the Weibull distribution in 'R'? I found the
following reference:
http://www.weibull.com/LifeDataWeb/weibull_log_likelihood_functions_and_their_partials.htm
But I had a hard time understanding the parameters required Particularly
'number of groups of
Yes. See the append option in write.table. This is okay for outputing results
but you will not be able to use the data in R.
--- On Tue, 8/5/08, Rajasekaramya [EMAIL PROTECTED] wrote:
From: Rajasekaramya [EMAIL PROTECTED]
Subject: [R] write .table
To: r-help@r-project.org
Received:
If you first install a newer version of R and aftwards remove a previous
version, Tinn-R gives this behaviour. Doesn't matter if you activate the
option to register.
Best regards
Bart
Philippe Grosjean wrote:
Paul Chatfield wrote:
Hi - someone has just e-mailed me direct with the answer
I am facing a problem in merging two datasets.
I have given codes to the names which are common in both the datasets and
also to those which are uncommon.
When I gave gave the following command
merge(df1,df2)
only those rows and columns were merged which were having common codes.
When I viewed
Hello R-User!
I appologise in advance if this should also go into statistics but I am
presently puzzled.
I have a data.frame (about 300 rows and about 80 variables) and my variables
are dichotomous factors, continuous (numerical) and ordered factors.
I would like to calculate the linear
merge(df1,df2,by=commonvar,all=T)
Regards,
Leandro Marino
-Mensagem original-
De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
nome de Shreyasee Pradhan
Enviada em: quarta-feira, 6 de agosto de 2008 11:15
Para: r-help@r-project.org
Assunto: [R] Merging two datasets
I am facing a
Hi Birgitle,
... my variables are dichotomous factors, continuous (numerical) and
ordered factors. ...
Now I am confused what I should use to calculate the correlation using
all my variables
and how I could do that in R.
Professor Fox's package polycor will do this for you in a very nice
Try using:
merge(df1, df2, all = TRUE)
On Wed, Aug 6, 2008 at 11:15 AM, Shreyasee Pradhan
[EMAIL PROTECTED] wrote:
I am facing a problem in merging two datasets.
I have given codes to the names which are common in both the datasets and
also to those which are uncommon.
When I gave gave the
Hi,
I do not get how par works, help please.
Let's say I have a simple plot: plot(1:10)
I want to change the font size for the x axis... how do I do that?
Thank you,
Stephane
--
The Wellcome Trust Sanger Institute is operated by Genome Research
Limited, a charity
Hi all,
I'd like to fit a multivariate regression with the variance of the error term
porportional to the predictors, like the WLS in the univariate case.
y_1~x_1+x_2
y_2~x_1+x_2
var(y_1)=x_1*sigma_1^2
var(y_2)=x_2*sigma_2^2
cov(y_1,y_2)=sqrt(x_1*x_2)*sigma_12^2
How can I specify
Hi,
See http://sourceforge.net/forum/forum.php?thread_id=1741502forum_id=481901
I'm running under Windows Server 2003, Standard x64 Edition and (I think) I
can't make any system wide registry changes. In my R installation there
are (I think) no relevant registry entries. I think that may be
Many, many thanks that was fast and exactly what I was looking for.
B.
Mark Difford wrote:
Hi Birgitle,
... my variables are dichotomous factors, continuous (numerical) and
ordered factors. ...
Now I am confused what I should use to calculate the correlation using
all my variables
Stephane Bourgeois wrote:
Hi,
I do not get how par works, help please.
Let's say I have a simple plot: plot(1:10)
I want to change the font size for the x axis... how do I do that?
Well, you start by reading help(par) multiple times, and then play
around
Start with, e.g.
On Wed, 6 Aug 2008, Stephane Bourgeois wrote:
Hi,
I do not get how par works, help please.
Let's say I have a simple plot: plot(1:10)
I want to change the font size for the x axis... how do I do that?
You mean of the tick labels (as distinct from the ylab)? Look at
plot(1:10,
On Wed, 6 Aug 2008, Prof Brian Ripley wrote:
Your examples work for me via read.dta() and via use(), including the Date
columns, with the current foreign_0.8-28. They also work on Windows 2.7.1
with foreign_0.8-26.
As far as I can see the only relevant part of read.dta is
On Wed, Aug 06, 2008 at 03:37:48PM +0100, Stephane Bourgeois wrote:
Hi,
I do not get how par works, help please.
Let's say I have a simple plot: plot(1:10)
I want to change the font size for the x axis... how do I do that?
OK, so firstly go to the help page for par by
Howdy,
Referencing the below exchange:
https://stat.ethz.ch/pipermail/r-help/2006-April/103862.html
I am still getting the same warning (non-integer #successes in a
binomial glm!) when using svyglm:::survey. Using the API data:
library(survey)
data(api)
#stratified sample
Hadley makes a good point. Boxplots should be standardized. Thre is already
inconsistency in what value the wiskers represent.
Violin plots with means and 95% CI are a good option if you want to show the
shape of a distribution with the mean. You could add the median as well.
That's what I did
For a log-likelihood, just sum values of dweibull(x, log=TRUE)
On Wed, 6 Aug 2008, [EMAIL PROTECTED] wrote:
Is there a likelihod function for the Weibull distribution in 'R'? I found the
following reference:
Hi,
Consider the following
x = c(1,2)
y = c(3,4)
d = data.frame(cbind(x,y))
d$x
[1] 1 2
d$x
[1] 1 2
foo = function(val)
+ {
+ return(d$val)
+ }
bar = function()
+ {
+ return(d$x)
+ }
foo(x)
NULL
bar()
[1] 1 2
I'm a little surprised that R accepts both the form d$x and d$x,
Hello,
I am currently trying to run a series of models (all combinations of 4
independent factors, non-duplicate) and selecting the best one to describe my
data. I was wondering if anyone knew of a way to get AIC and Likelihood values
from R when using reduced major axis regression (RMA). I
I looked at 'merge'. What if df1 and df2 are data.frames and I want to merge on
on column and sum on another? Say df1 and df2 are data.frames with columns
'ID1', 'ID2', 'ID3', and 'Qty'. I want to 'merge' the data frames (and produce
a new data.frame) if there is a matching 'ID2' in each
Hi, everybody!
I am an experienced senior programmer, but absolutely newbie in R, so excuse me
if my question is too silly.
I need for my work to evaluete some greek text statistically. The text is in a
Windows Unicode file, so I read it in via
folks,
is there a better way to convert a daily series of price returns to a monthly
one than as follows:
library(xts)
a - xts(rnorm(100) / 100, order.by = as.Date(1:100))
am - diff(to.monthly(cumsum(a))[, 4]) # [, 4] for Close levels
the problem with this is that the entire first month of
Hi everyone,
This is a graphics question, concerning presentation rather than
actually producing figures.
After much fiddling I've managed to create bar plots showing error
bars. I've put in an x-axis, which goes along all the bars, but
doesn't appear between the y-axis and the first bar. I've
I have a matching problem that I cant solve.
mystring = xxx{XX}yy{YYY}zzz{Z} where x,X,y,Y,z,Z basiclly can
be anything, letters, digits etc. I'm only interested in the content within
each {}.
I am close but not really there yet.
library(gsubfn)
strapply(mystring,\\{[^\\}]+,, perl=F)
gives me
Try this
foo1 = function(val)
{
return(d[val])
}
foo1(x)
Good luck
miltinho astronauta
brazil
On 8/6/08, Faheem Mitha [EMAIL PROTECTED] wrote:
Hi,
Consider the following
x = c(1,2)
y = c(3,4)
d = data.frame(cbind(x,y))
d$x
[1] 1 2
d$x
[1] 1 2
foo = function(val)
One option is:
strapply(mystring, \\{[^\\}]+ , function(x)gsub(\\{, , x), perl = F)
On Wed, Aug 6, 2008 at 10:01 AM, Tom.O [EMAIL PROTECTED] wrote:
I have a matching problem that I cant solve.
mystring = xxx{XX}yy{YYY}zzz{Z} where x,X,y,Y,z,Z basiclly can
be anything, letters, digits etc.
On Wed, 6 Aug 2008, milton ruser wrote:
Try this
foo1 = function(val)
{
return(d[val])
}
foo1(x)
Thanks for the suggestion. I appreciate it. My original question wasn't
just a pragmatic how do I do this type question. I was also wondering
about the language issues involved.
On Wed, Aug 6, 2008 at 9:01 AM, Tom.O [EMAIL PROTECTED] wrote:
I have a matching problem that I cant solve.
mystring = xxx{XX}yy{YYY}zzz{Z} where x,X,y,Y,z,Z basiclly can
be anything, letters, digits etc. I'm only interested in the content within
each {}.
I am close but not really there
On Wed, 6 Aug 2008, Weltler Rezső - Contenuto Bt. wrote:
Hi, everybody!
I am an experienced senior programmer, but absolutely newbie in R, so
excuse me if my question is too silly.
I need for my work to evaluete some greek text statistically. The text
is in a Windows Unicode file, so I
On Wed, 6 Aug 2008, Faheem Mitha wrote:
Hi,
Consider the following
x = c(1,2)
y = c(3,4)
d = data.frame(cbind(x,y))
d$x
[1] 1 2
d$x
[1] 1 2
foo = function(val)
+ {
+ return(d$val)
+ }
bar = function()
+ {
+ return(d$x)
+ }
foo(x)
NULL
bar()
[1] 1 2
I'm a little surprised
On Wed, 6 Aug 2008, Hanna Granroth wrote:
Hi everyone,
This is a graphics question, concerning presentation rather than
actually producing figures.
After much fiddling I've managed to create bar plots showing error
bars. I've put in an x-axis, which goes along all the bars, but
doesn't appear
You need to do the merge and then sum in a separate operation
I think you may have to rename the columns. See ?names
--- On Wed, 8/6/08, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
From: [EMAIL PROTECTED] [EMAIL PROTECTED]
Subject: Re: [R] Merging two datasets
To: Henrique Dallazuanna [EMAIL
Dear R wizards,
I have a folder containing 1000 files. For each file, I need to extract the
first row of each file, paste it to a new file, then write out that file. Then
I need to repeat this operation for each additional row (row 2, then row 3,
etc) for 23 rows in each file.
I can do
Hi; I'm trying to install R in a computer in which I have only non-root
access, and I've got readline in a local own directory.
I cannot find my way to compile with readline. I've tried:
[sun2]/global/jgarcia/SRC/R/R-2.7.1: ./configure
--prefix=/global/jgarcia/BIN/R
Mac OS X 10.5.4
intel processor
R 2.7.1
MacTex - latest version (yesterday and checked for updates)
I am trying to diagnose a documentation issue. I don't know TeX at
all- I may have a friend who does I will find out tonight, but this is
more of a procedural question. I have Read the FAQ, R
(A) I received the following bounced message when I tried to submit a
bug from http://bugs.r-project.org/cgi-bin/R
(B) The bug report itself is at the bottom.
Thanks,
Chris
(A)
Original Message
Subject:Undelivered Mail Returned to Sender
Date: Wed, 6 Aug 2008
On Wed, 6 Aug 2008, zack holden wrote:
Dear R wizards,
I have a folder containing 1000 files. For each file, I need to extract the
first row of each file, paste it to a new file, then write out that file. Then
I need to repeat this operation for each additional row (row 2, then row 3,
etc)
Hi all,
is there a Normal score(nscore) function to download?
Because when I try:
rsam.sc - nscore(rsam)
Error: don't find nscorefunction
Thanks
Ale
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
Hi,
I'm sorry for the quick question, I've have just found the correct syntax
(in an old message of
Prof.Ripley to the list), compiled correclty the code, and checked
everything goes fine.
Best wishes,
Javier
---
Hi; I'm trying to install R in a computer in which I have only
on 08/06/2008 01:36 PM Alessandro wrote:
Hi all,
is there a Normal score(nscore) function to download?
Because when I try:
rsam.sc - nscore(rsam)
Error: don't find nscorefunction
Thanks
Ale
It would be helpful to know where you heard about the function. The only
reference that I can
Look at config.log for why it fails to find readline. We can't help you
without it.
On Wed, 6 Aug 2008, [EMAIL PROTECTED] wrote:
Hi; I'm trying to install R in a computer in which I have only non-root
access, and I've got readline in a local own directory.
I cannot find my way to compile
Hello,
I am currently evaluating different ways to analyse a specific multiple
species monitoring system. One idea is to identify the important covariates
with random forest. However, there are some points I have problems to get my
head around.
1. I have observations from a GRID with 25
I find that some packages, that I need, do not always work with the
latest version of R. For that reason I always keep earlier versions
of R and the relevant old packages and run it in parallel with the
latest version. I use Tinn-R and use the RSetReg.exe from the
relevant bin directory to
Hi,
How can I make the distance between an axis-label and the axis bigger?
I haven't found anything in par()...
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
Hi Jörg,
I haven't found anything in par()...
No? Well don't bet your bottom $ on it (almost never in R). ?par (sub mgp).
Mark.
Jörg Groß wrote:
Hi,
How can I make the distance between an axis-label and the axis bigger?
I haven't found anything in par()...
On Wed, 6 Aug 2008, Jörg Groß wrote:
How can I make the distance between an axis-label and the axis bigger?
I haven't found anything in par()...
Look at mgp. Depending what you mean by 'axis-label' one of its three
values is relevant.
--
Brian D. Ripley, [EMAIL PROTECTED]
on 08/06/2008 03:21 PM Jörg Groß wrote:
Hi,
How can I make the distance between an axis-label and the axis bigger?
I haven't found anything in par()...
Depends upon what you mean by the axis labels...
If by axis labels, you are referring to the text annotation typically
centered on the
Hi
Peter Cowan wrote:
Hello all,
I'm trying to write a function that produces a main plotting region
with several square plots along the right side. Ideally the size of
right side plots will scale only with the height of the entire plot,
yet never overlap with another secondary plot.
Chris Andrews wrote:
(A) I received the following bounced message when I tried to submit a
bug from http://bugs.r-project.org/cgi-bin/R
(B) The bug report itself is at the bottom.
Aargh... Support staff alerted.
Presumably, this happened in connection with the server move in early
July.
Hi everyone,
I'm trying to use the acf() function to calculate the autocorrelation of
each column in a matrix. The trouble is that I can only seem to get the
function to work if I extract the data in the column into a separate matrix
and then apply the acf() function to this column.
I have
You could try using sink() instead of write.table() to append the clustering .
write.table(myclara$data,cluster.dat)
sink(cluster.dat,append=TRUE)
print( myclara$clustering )
sink()
That will definitely append clustering to the file.
-Don
At 6:49 PM +0200 8/1/08, pacomet wrote:
HI R users
Hi, here is one possible solution ...
-gary
### example ###
# create a 500x3 multi-ts
A - matrix(rnorm(1500),nrow=500)
# misc. graphical setting
par(mfrow=c(ncol(A),1))
# then our friend -- lapply(split(...))
lapply(split(A,col(A)), acf)
#Or
lapply(split(A,col(A)), function(ts) acf(ts,
Hi,
Yes. this is a way, and relatively easy ... Using Reduce. Note: in
order to use Reduce, you need an update-to-date version of R. I'm
using 2.6.2.
First you have to have all the matrices line up with correct dimensions,
i.e. [m_1 x m_2] %*% [m_2 x m_3] %*% ... %*% [m_(n-1) x m_n] (u get my
Dear Marc,
I'd been used the acceptance sampling but it is not possible to minimize
given that problem. It fits very well to calculate, but it's necessary have
an acceptance plan defined to assess the probabilities (p1,p2) and consumer
and producer risks...
Thank you for the tips.
EToktar
I was posed the following problem/teaser:
given two matrices, come up with an elegant (=fast short) function that
returns a matrix with all and only the non-duplicated columns of both
matrices; the column order does not matter. In essence, a matrix equivalent
of union(x,y), where x and y are
Hello,
I am trying to install R packages under linux, some of the packages can
not be installed and I got the following errors, could anybody give me
suggestion on where the problem is and how to fix them? Thanks -e
.libPaths()
[1] /usr/lib64/R/library
Here is my attempt. I'm not sure if that's the most efficient way to do
it, cause I'm cheating using the nice features from R, namely
duplicated().
I assume the matrices have same number of rows.
### example ###
### background setup: simulate 2 matrices with some common columns
(A - cbind(1:4,
Hi
Arthur Roberts wrote:
Hi, all,
I would like to know if there is any gui interface out there
(academic or commercial) that allows one to edit R-language generated
graphs (e.g positioning x axis labels.) It would be nice to have
something like the user interface of Igor or
Hello,
I am trying to install R packages under linux, some of the packages can
not be installed and I got the following error, could anybody give me
suggestion on where the problem is and how to fix it? Thanks-e
.libPaths()
[1] /usr/lib64/R/library
[2]
If a and b are your matrices of common row length, unique() can solve
it:
unique(cbind(a,b), MARGIN=2)
Eric
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Giuseppe Paleologo
Sent: Wednesday, August 06, 2008 3:33 PM
To: r-help@r-project.org
Subject:
It isn't (and never was) indicative of a problem. You can make the warning
go away by using quasibinomial() instead of binomial(), as in the example
on the help page.
Incidentally, it's survey::svyglm (::, not :::)
-thomas
On Wed, 6 Aug 2008, Ben Domingue wrote:
Howdy,
On 7/08/2008, at 10:58 AM, stephen sefick wrote:
using R CMD Rd2dvi --pdf foo.Rd creates pdfs for everyone of the
files separately. What do I do now?
Back off a bit. I.e. go up two levels to the directory containing
your package source. Then do
R CMD Rd2dvi --pdf package name
Fernando Marmolejo Ramos fernando.marmolejoramos at adelaide.edu.au writes:
Dear R users
Lets assume I have the following batches of data
a - rnorm(20,200,100)
b - rnorm(20,250,100)
c - rnorm(20,300,100)
# I plot them as violin plots
require(vioplot)
vioplot(a, b, c)
# I plot
Hi, you could try to do:
text(x,y, expression(paste(A) ,Delta,stbA::cat)); # uppercase 'D'elta
text(x,y, expression(paste(A) ,delta,stbA::cat)); #lowercase 'd'elta
or yet
text(x,y, A) \\*DstbA::cat, vfont=c(serif, plain))
# here there are too many examples...
demo(plotmath)
'Alpha' -
Hey Guys,
Thanks for the suggestions and instant reply.
merge(df1, df2, all=TRUE)
worked for my datasets.
And yes, I had rename the columns before doing that, as there were special
characters in the variables.
Thanks,
Shreyasee
On Wed, Aug 6, 2008 at 10:42 PM, John Kane [EMAIL PROTECTED]
colorRampPalette() may do what you want.
-thomas
On Wed, 6 Aug 2008, Daniel Bernstein wrote:
Hello there! I'd just like to say in advance, Thank you, for any help and/or
advice.
My problem is as follows:
I have a dataset that is made up of percentages. I've assigned my error
Your example works in R-patched, as a consequence of investigations of a
different problem. (See the comments in the posting guide about updating
your R and trying the very latest versions.)
Windows binaries for R-patched are available on CRAN.
On Tue, 5 Aug 2008, Keith Jewell wrote:
Hi
86 matches
Mail list logo