lmer is not designed for ordered categorical data as yours are. You could
take a look at the ordinal package which is designed for this type of data
including mixed models (function clmm) which you probably want to use.
Best,
Rune
Den 24/03/2011 21.03 skrev "Rasanga Ruwanthi" :
>
> Dear List,
>
>
I have figured out the solution to this. It appears that "distance" isn't
defined as the difference in propensity scores. Instead, this difference is
then scaled by the standard deviation of the predicted dependent-variable
values of the corresponding logistic regression, and then squared.
Theref
Dear expeRts,
How can I get ...
(1) different y-axis scales for each row
(2) while having the same y-axis scales for different columns?
I coulnd't manage to do this with relation="free" [which gives (1) but not (2)].
I also tried relation="sliced", but it did not give the same y-axis scales
wit
Dear expeRts,
How can I get plotmath-labels in the bwplot below?
As you can see, I couldn't manage to pass the expressions through the dimnames
argument.
Cheers,
Marius
library(lattice)
## data
dim <- c(100, 6, 2, 3)
dimnames <- list(n=paste("n=", seq_len(100), sep=""),
grou
Without more detailed information I would say that R runs out of
memory...and furthermore:
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
cheers,
Paul
On 03/25/2011 11:32 PM, mipplor wrote:
i run
sammyny caa.columbia.edu> writes:
>
> I am trying to use
> http://rss.acs.unt.edu/Rdoc/library/stats/html/constrOptim.html in R to do
> optimization in R with some given linear constraints but not able to figure
> out how to set up the problem.
>
> For example, I need to maximize $f(x,y) = log(x
Dear all,
is there a convenient way to determine the effect size for a regression
coefficient in a multiple regression model?
I have a model of the form lm(y ~ A*B*C*D) and would like to determine
Cohen's f2 (http://en.wikipedia.org/wiki/Effect_size) for each predictor
without having to do it manu
Hi Michael,
You can just fit your model, and then use anova() to get the Sum of Squares.
## fit and store model
m <- lm(mpg ~ hp * wt * vs, data = mtcars)
## store ANOVA from model
msum <- anova(m)
## divide all Sums of Squares by the sum() of the Sums of Squares
msum[["Sum Sq"]]/sum(msum[["Sum S
Hello,
I am trying to come up with a routine to calculate a rolling mean and
standard deviation for three parameters stored in a NetCDF file. The NetCDF
file contains 10 years of daily records for each of the three parameters,
and I need the statistics for each of the three parameters.
Below I i
Hi Nick,
Thanks a lot for your quick response.
Sorry for delayed response becasue of time difference between us.
(11/03/25 22:40), Nick Sabbe wrote:
> > I haven't read all of your code, but at first read, it seems right.
> >
> > With regard to your questions:
> > 1. Am I doing it correctly or not?
(11/03/26 0:12), Mike Marchywka wrote:
Would you post your data or if you did I missed it?
Sorry, I did not. This is patients' data and I have to obtain some
permission from my office to send it, so ...
I don't have an answer for you but curious as I was
interested in similar analyses with
Does anyone know if it is possible to get the length of the log phase (the
main growth phase) from a grofit logistic model?
I can get the lag phase length, maximum growth and max rate of growth, but I
also want to know the length of the log phase (ie, for how long do the
bacteria grow exponentiall
On 25.03.2011 23:32, mipplor wrote:
i run a model ,but i turn out to be like this. but i have run this model days
ago and it works well
whats going on here? any suggestion.
If it worked exactly the way before on the same machine, you probably
have too huge objects in your workspace.
Uwe
On Mar 26, 2011, at 4:47 AM, Marius Hofert wrote:
Dear expeRts,
How can I get plotmath-labels in the bwplot below?
As you can see, I couldn't manage to pass the expressions through
the dimnames
argument.
It would have been helpful, and may still be necessary, for you to
explain more ful
Some years ago I travelled through Libya and it's with much emotion
that I follow the news.
The license below is dedicated to Mohammed Nabbous and will let you
run xlsReadWritePro for free (Windows, R 32-bit):
library( "xlsReadWritePro" )
xls.lic( action = "register",
miscData = list(
Dear David,
many thanks, that was it.
Cheers,
Marius
On 2011-03-26, at 18:04 , David Winsemius wrote:
>
> On Mar 26, 2011, at 4:47 AM, Marius Hofert wrote:
>
>> Dear expeRts,
>>
>> How can I get plotmath-labels in the bwplot below?
>> As you can see, I couldn't manage to pass the expression
Hello,
I would like to take advantage of the upper.tri() function here but I don't
know exactly. Here is some working code...
i<-5
fi<-matrix(0,nrow=i,ncol=i)
for(r in 1:i){
for(c in 1:i){
if(r==c){
fi[r,c]<-1
}else if(rhttps://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
Nutter, Benjamin ccf.org> writes:
I've noticed it, but I haven't looked into it much since I rarely work
on Vista. I have found that opening R before I open Tinn-R tends to
work better than using Tinn-R to open the preferred GUI.
Benjamin
-Original Message-
From: r-help-boun
Is anyone familiar with a way to account for sampling weights (e.g., in order
to cope with selection bias) for individual respondents using the bayesm
package (e.g., rhierMnlRwMixture)?
In the regular MNL this can easily be done in STATA using the mlogit
function with pweights option. However, I a
Hi,
I am trying to get TextWrangler to work with LaTeX and Sweave. Ideally
I would call a script from TextWrangler that would run Sweave on a
document, then LaTeX (using SyncTeX), and finally
open the corresponding pdf in Skim. Of course I don't always need to
run Sweave and would be looking for th
On Mar 26, 2011, at 9:44 AM, Brian Pellerin wrote:
Hello,
I would like to take advantage of the upper.tri() function here but
I don't
know exactly. Here is some working code...
i<-5
fi<-matrix(0,nrow=i,ncol=i)
for(r in 1:i){
for(c in 1:i){
if(r==c){
fi[r,c]<-1
}else if(rfi[lower.tri(fi)]<-f
On 11-03-26 10:58 AM, Christopher Desjardins wrote:
Hi,
I am trying to get TextWrangler to work with LaTeX and Sweave. Ideally
I would call a script from TextWrangler that would run Sweave on a
document, then LaTeX (using SyncTeX), and finally
open the corresponding pdf in Skim. Of course I don't
The contributed package e1071 does exactly what I want except that I
need to have (1) the abscissa and ordinate axes swapped, with the
probability scale on the bottom and the quantiles scale on the LHS.
Using the following example:
library(e1071)
x <- rnorm(100, mean=5)
probplot(x, line=FALSE
Hi
How can I return the index of sort, when I use R function sort?
or any other sorting functions in R
For example, I sorted a vector, but R just return the sorted value without
giving me the original index of these data.
Thanks a lot.
[[alternative HTML version deleted]]
___
Hi,
> a <- 4
> a*0.2
[1] 0.8
ok!!
Is there a method to obtain this:
> a*0.2
[1] 0.80
I need to round the number also with the zero.
Thanks in advance,
Alfredo
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLE
On Mar 26, 2011, at 4:06 PM, Thomas Adams wrote:
The contributed package e1071 does exactly what I want except that I
need to have (1) the abscissa and ordinate axes swapped, with the
probability scale on the bottom and the quantiles scale on the LHS.
Using the following example:
library
On Mar 26, 2011, at 2:03 PM, Quan Zhou wrote:
Hi
How can I return the index of sort, when I use R function sort?
or any other sorting functions in R
For example, I sorted a vector, but R just return the sorted value
without
giving me the original index of these data.
You seem to be looking
David,
Thanks! This is very helpful! I'm still very much a novice…
Tom
On 3/26/11 4:11 PM, David Winsemius wrote:
On Mar 26, 2011, at 4:06 PM, Thomas Adams wrote:
The contributed package e1071 does exactly what I want except that I
need to have (1) the abscissa and ordinate axes swapped, w
On 11-03-26 2:05 PM, Alfredo Alessandrini wrote:
Hi,
a<- 4
a*0.2
[1] 0.8
ok!!
Is there a method to obtain this:
a*0.2
[1] 0.80
It is easy to print values with trailing zeros, but I think it's hard to
make it the default. The sprintf() function is the one I'd use for the
formatting
Hi Alfredo,
Try
noquote(sprintf("%.2f", a*.2))
HTH,
Jorge
On Sat, Mar 26, 2011 at 2:05 PM, Alfredo Alessandrini <> wrote:
> Hi,
>
> > a <- 4
>
> > a*0.2
> [1] 0.8
>
> ok!!
>
> Is there a method to obtain this:
>
> > a*0.2
> [1] 0.80
>
> I need to round the number also with the zero.
>
>
>
> T
On Sat, Mar 26, 2011 at 07:05:40PM +0100, Alfredo Alessandrini wrote:
> Hi,
>
> > a <- 4
>
> > a*0.2
> [1] 0.8
>
> ok!!
>
> Is there a method to obtain this:
>
> > a*0.2
> [1] 0.80
>
> I need to round the number also with the zero.
Hi.
Try the following
formatC(a*0.2, digits=2, format="f
Hi,
I am working on some line charts and although I have a lot of resources, I
cannot seem to find an answer to this question: how can I set the
incrementation of values on the x-axis values so that I can see all the
groups on this axis. Right now, R puts them at increments of 2 (i.e., 2, 4,
6, 8,
On 03/27/2011 09:21 AM, Bulent Arikan wrote:
Hi,
I am working on some line charts and although I have a lot of resources, I
cannot seem to find an answer to this question: how can I set the
incrementation of values on the x-axis values so that I can see all the
groups on this axis. Right now, R p
Bulent -
Many characteristics of plots are determined by the graphical
parameters documented in the help file for the par function.
In this case, the xaxp parameter should be useful. Compare
plot(1:12,1:12)
with
plot(1:12,1:12,xaxp=c(0,12,12))
- Phil
Hi everyone,
I have just got different samples from a dataframe (independent and
exclusive, there aren't common elements among them). I want to create a
variable that indicate the sampling selection of the elements in the
original dataframe (for example, 0 = no selected, 1= sample 1, 2=sample
This way uses a three-dimensional array instead of the nested apply.
It seems to take the same amount of time, even on larger datasets, but
it may give you ideas.
distance=function(x) daisy(x, metric = 'gower')
persons=array(dim=c(2,nrow(donor)*nrow(receiver),ncol(receiver)))
persons[1,,]=donor[r
On Mar 26, 2011, at 7:05 PM, Sebastián Daza wrote:
Hi everyone,
I have just got different samples from a dataframe (independent and
exclusive, there aren't common elements among them). I want to
create a variable that indicate the sampling selection of the
elements in the original datafra
Hi,
I've created 3 plots one under the other, and want to include a legend on
the right that spans the height of all 3 plots.
How can I do this?
Thanks!
--
View this message in context:
http://r.789695.n4.nabble.com/Multiple-plots-with-one-legend-tp3408537p3408537.html
Sent from the R help mai
Posting some sample data would help, but I think something like this
is what you want
data[data$school=='Cornell University',]
For example
CO2[CO2$Type=='Quebec',]
Tom
2011/3/26 Sebastián Daza :
> Hi everyone,
> I have just got different samples from a dataframe (independent and
> exclusive, t
On Mar 26, 2011, at 7:06 PM, mavkoup wrote:
Hi,
I've created 3 plots one under the other, and want to include a
legend on
the right that spans the height of all 3 plots.
?mtext
# with the `las` parameter for rotation
Or you can use:
text(x,y, "some text", srt=-90,xpd=NA )
--
Davi
Ok I think I can figure that out. Which leads me to a further question. My 3
plots contain 10 time series, each with a different name and color. Can I
create the legend such that it has a line of the correct color follow by the
name of the series? I.e.
line(with color1) NAME 1
line(with color2) NA
Hello R people
Is there a way to get the coordinates of the text region (coordinates of the
four corners for example) when using the text function? I'm looking for a way
that does not make use of interactive function like locator. My goal is to
determine the position of other structures in a
On Mar 26, 2011, at 8:27 PM, mavkoup wrote:
Ok I think I can figure that out. Which leads me to a further
question. My 3
plots contain 10 time series, each with a different name and color.
Can I
create the legend such that it has a line of the correct color
follow by the
name of the serie
On Mar 26, 2011, at 8:39 PM, Francois Rousseu wrote:
Hello R people
Is there a way to get the coordinates of the text region
(coordinates of the four corners for example)
What "text region" are you talking about?
when using the text function? I'm looking for a way that does not
make us
Let's say I do the following:
plot(0,0,type="n",xlim=c(0,10),ylim=c(0,10))
rect(4,5,5,6,border="black",col="white")
text(4.5,5.5,"species",cex=2)
I would like to be able to determine a rectangle size that will be able to
contain the text species. I'm working on a function using multiple lines
take a look at 'textbox' in plotrix.
On Sat, Mar 26, 2011 at 9:05 PM, Francois Rousseu
wrote:
>
> Let's say I do the following:
>
> plot(0,0,type="n",xlim=c(0,10),ylim=c(0,10))
> rect(4,5,5,6,border="black",col="white")
> text(4.5,5.5,"species",cex=2)
>
> I would like to be able to determine a re
You can use 'layout' to create 4 plot areas: the 3 plot you currently
have, and one for the legend. Try this to see what happens:
> x <- cbind(rbind(1,2,3), 4)
> layout(x, width = c(5,1))
> layout.show(4)
On Sat, Mar 26, 2011 at 7:06 PM, mavkoup wrote:
> Hi,
>
> I've created 3 plots one under
There is some information about this subtype in the PSPP source code,
and for other subtypes not yet implemented by read.spss. The PSPP source
code indicates that this subtype consists of "Value labels for long
strings", which isn't very illuminating to me (probably because I don't
use PSPP, or SPS
Thanks, David. This works splendidly. Thanks for your help.
Sincerely,
Brian
>>> David Winsemius 03/26/11 3:06 PM >>>
On Mar 26, 2011, at 9:44 AM, Brian Pellerin wrote:
> Hello,
>
> I would like to take advantage of the upper.tri() function here but
> I don't
> know exactly. Here is some wor
Look at the strwidth and strheight functions. Also note the adj parameter (see
?par for details).
--
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-
Yes that's what I had managed to generate too. I can produce my 3 plots. Each
plot has 10 colored lines say. I want to place the legend in the 4th spot
listing the name of the 10 colored lines, and their color.
--
View this message in context:
http://r.789695.n4.nabble.com/Multiple-plots-with-one
There appear to be reports in the literature that transform continuous
independent variablea by the use of splines, e.g., assume the dependent
variable is hot dogs eaten per week (HD) and the independent variable is
waistline (WL), a normal linear regression model would be:
nonconfusing_regressio
Dear List,
I'm now using Ubuntu 10.10 and I want to use the garchoxfit
function.It seems that I need to download the package.
While after installing the package,I still can't use the garchoxfit
function.What's the reason and how to fix that?
Thanks for your time!
Best,
Ning
I was wondering if it is possible to do the following in a smarter way.
I want get the mean value across the columns of a matrix, but I want
to do this on subrows of the matrix, given by some vector(same length
as the the number of rows). Something like
nObs<- 6
nDim <- 4
m <- matrix(rnorm(
On Mar 26, 2011, at 11:16 PM, Ning Cheng wrote:
Dear List,
I'm now using Ubuntu 10.10 and I want to use the garchoxfit
function.It seems that I need to download the package.
While after installing the package,I still can't use the garchoxfit
function.What's the reason and how to fix that?
A
On Mar 26, 2011, at 10:26 PM, fisken wrote:
I was wondering if it is possible to do the following in a smarter
way.
I want get the mean value across the columns of a matrix, but I want
to do this on subrows of the matrix, given by some vector(same length
as the the number of rows). Something
56 matches
Mail list logo