Re: [R] Likelihood ratio test in porl (MASS)

2016-07-27 Thread Faradj Koliev
his helps, > John > > - > John Fox, Professor > McMaster University > Hamilton, Ontario > Canada L8S 4M4 > Web: socserv.mcmaster.ca/jfox > > > > >> -Original Message- >> From: R-help [mailto:r-help-boun...@r-pr

Re: [R] Likelihood ratio test in porl (MASS)

2016-07-27 Thread Fox, John
is helps, John - John Fox, Professor McMaster University Hamilton, Ontario Canada L8S 4M4 Web: socserv.mcmaster.ca/jfox > -Original Message- > From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Faradj Koliev > Sent: July 27, 2016 4:50 AM > To: r-help@r-project.or

Re: [R] Likelihood ratio test in porl (MASS)

2016-07-27 Thread Achim Zeileis
On Wed, 27 Jul 2016, Faradj Koliev wrote: Dear all, A quick question: Let?s say I have a full and a restricted model that looks something like this: Full<- polr(Y ~ X1+X2+X3+X4, data=data, Hess = TRUE, method="logistic?) # ordered logistic regression Restricted<- polr(Y ~ X1+X2+X3, data=da

[R] Likelihood ratio test in porl (MASS)

2016-07-27 Thread Faradj Koliev
Dear all, A quick question: Let’s say I have a full and a restricted model that looks something like this: Full<- polr(Y ~ X1+X2+X3+X4, data=data, Hess = TRUE, method="logistic”) # ordered logistic regression Restricted<- polr(Y ~ X1+X2+X3, data=data, Hess = TRUE, method="logistic”) # or

Re: [R] likelihood ratio test for mean difference assuming unequal variance

2014-01-13 Thread Ben Bolker
Amanda Li uchicago.edu> writes: > > Hello, > > I am so sorry, but I have been struggling with > the code for the entire day. > > I have a very simple dataset that looks like this: > response=c(45,47,24,35,47,56,29) > sub=c("A","A","B","B","C","C","C"£© > time=c(1,2,1,2,1,2,3) > gdata=cbind(re

[R] likelihood ratio test for mean difference assuming unequal variance

2014-01-13 Thread Amanda Li
Hello, I am so sorry, but I have been struggling with the code for the entire day. I have a very simple dataset that looks like this: response=c(45,47,24,35,47,56,29) sub=c("A","A","B","B","C","C","C"£© time=c(1,2,1,2,1,2,3) gdata=cbind(response,sub,time) Namely, for three subjects, each has 2 o

Re: [R] Likelihood

2013-05-03 Thread S Ellison
> I have run a regression and want to calculate the likelihood > of obtaining the sample. > Is there a way in which I can use R to get this likelihood value? See ?logLik And see also ?help.search and ??. You would have found the above by typing ??likelihood at the command line in R S Ellison

[R] Likelihood

2013-05-02 Thread Preetam Pal
Hi all, I have run a regression and want to calculate the likelihood of obtaining the sample. Is there a way in which I can use R to get this likelihood value? Appreciate your help on this. The following are the details: raw_ols1=lm(data$LOSS~data$GDP+data$HPI+data$UE) summary(raw_ols1) Call

[R] Likelihood ratio test for comparing non-nested cox models

2013-05-01 Thread Hans-Ulrich Klein
Dear All, I fitted two non-nested proportional hazards models using the coxph() function from package survival. Now, I would like to apply a model selection test like, e.g., the likelihood ratio test proposed by Vuong. I found an implementation of Vuong's test in the package 'pscl', but that

Re: [R] Likelihood ratio

2012-11-10 Thread David Winsemius
On Nov 10, 2012, at 11:57 AM, bgnumis bgnum wrote: > Hi All > > > I have to run multiple stimations and to compute Likelihhod ratio. > > If I compute ls function with coef and summary I can extract "outputs" that > I need. Do you mean "lm"? > > I am not able to find something similar to lo

[R] Likelihood ratio

2012-11-10 Thread bgnumis bgnum
Hi All I have to run multiple stimations and to compute Likelihhod ratio. If I compute ls function with coef and summary I can extract "outputs" that I need. I am not able to find something similar to log liklihood Can you pease tell me running a ls function x on y how to extract if posib

Re: [R] likelihood function involving integration, error in nlm

2012-10-19 Thread stats12
Thanks for pointing that out. Made some modifications and it worked. -- View this message in context: http://r.789695.n4.nabble.com/likelihood-function-involving-integration-error-in-nlm-tp4646697p4646764.html Sent from the R help mailing list archive at Nabble.com. ___

Re: [R] likelihood function involving integration, error in nlm

2012-10-19 Thread Berend Hasselman
On 19-10-2012, at 04:40, stats12 wrote: > Dear R users, > > I am trying to find the mle that involves integration. > > I am using the following code and get an error when I use the nlm function > > d<-matrix(c(1,1,0,0,0,0,0,0,2,1,0,0,1,1,0,1,2,2,1,0),nrow=10,ncol=2) > h<-matrix(runif(20,0,1),

[R] likelihood function involving integration, error in nlm

2012-10-18 Thread stats12
Dear R users, I am trying to find the mle that involves integration. I am using the following code and get an error when I use the nlm function d<-matrix(c(1,1,0,0,0,0,0,0,2,1,0,0,1,1,0,1,2,2,1,0),nrow=10,ncol=2) h<-matrix(runif(20,0,1),10) integ<-matrix(c(0),nrow=10, ncol=2) ll<-function(p){

[R] Likelihood: Multiple Maxima

2012-10-05 Thread felix1984
Hi everyone, I estimate structural equation models and use maximum likelihood estimation. However, the estimates differ depeding on the starting values I choose, so I guess there are multiple local maxima. I'm new to R (and statistics...;), does anybody maybe know how I solve this best? Thanks a

Re: [R] Likelihood ratio test

2011-06-12 Thread Achim Zeileis
On Sun, 12 Jun 2011, Jorge Ivan Velez wrote: Hi Diviya, Take a look at the lrtest function in the lmtest package: install.packages('lmtest) require(lmtest) ?lrtest Yes, when you have to nls() fits, say m1 and m2, you can do lrtest(m1, m2) However, I don't think that both m1 and m2 can be i

Re: [R] Likelihood ratio test

2011-06-12 Thread Jorge Ivan Velez
Hi Diviya, Take a look at the lrtest function in the lmtest package: install.packages('lmtest) require(lmtest) ?lrtest HTH, Jorge On Sun, Jun 12, 2011 at 1:16 PM, Diviya Smith <> wrote: > Hello there, > > I want to perform a likelihood ratio test to check if a single exponential > or a sum of

[R] Likelihood ratio test

2011-06-12 Thread Diviya Smith
Hello there, I want to perform a likelihood ratio test to check if a single exponential or a sum of 2 exponentials provides the best fit to my data. I am new to R programming and I am not sure if there is a direct function for doing this and whats the best way to go about it? #data x <- c(1 ,10,

Re: [R] likelihood ratio test

2011-05-26 Thread Ben Bolker
karuna m yahoo.com> writes: > Can anybody tell me which R package has Lo-Mendell Rubin LR test and > Bootstrap > LR test to compare the model fit between k class and k+1 class model > for Latent class analysis? I don't know, but library("sos") findFn("Lo-Mendell") findFn("{latent class ana

[R] likelihood ratio test

2011-05-25 Thread karuna m
Dear R-help, Can anybody tell me which R package has Lo-Mendell Rubin LR test and Bootstrap LR test to compare the model fit between k class and k+1 class model for Latent class analysis? Thanks in advance,  warn regards,Ms.Karunambigai M PhD Scholar Dept. of Biostatistics NIMHANS Bangalore India

[R] likelihood for new data from fitted nlme object

2011-04-12 Thread Andrew Bateman
Dear list, I have a fitted nlme object from which I want to produce estimates of the (marginal) likelihood for new data, given the fitted model.  I am trying to cross validate a number of nonlinear mixed effects models, and I would like to find a way to calculate the marginal likelihood for "virgi

Re: [R] Likelihood of deviation

2011-03-25 Thread David Winsemius
On Mar 25, 2011, at 12:17 PM, Michael Hecker wrote: Hi, I have a dataset of 78.903 news articles pertaining to 340 corporate takeovers. Mean 231.3871 [articles per takeover] Std. Dev. 673.6395 I would like to calculate the probability of a certain number of news articles if I had more tak

[R] Likelihood of deviation

2011-03-25 Thread Michael Hecker
Hi, I have a dataset of 78.903 news articles pertaining to 340 corporate takeovers. Mean 231.3871 [articles per takeover] Std. Dev. 673.6395 I would like to calculate the probability of a certain number of news articles if I had more takeovers available. How likely is it to have X articles if

Re: [R] Likelihood ratio based confidence intervals for logistic regression

2010-04-30 Thread Peter Ehlers
On 2010-04-30 12:42, jh556 wrote: Some quick googling suggests that they are the same thing. Thanks for the help! And note that profile likelihood CIs are produced by default on glm objects, i.e. R uses MASS's confint.glm for glm objects. confint.default(your model) let's you compare with Wa

Re: [R] Likelihood ratio based confidence intervals for logistic regression

2010-04-30 Thread jh556
Some quick googling suggests that they are the same thing. Thanks for the help! -- View this message in context: http://r.789695.n4.nabble.com/Likelihood-ratio-based-confidence-intervals-for-logistic-regression-tp2077303p2077354.html Sent from the R help mailing list archive at Nabble.com. ___

Re: [R] Likelihood ratio based confidence intervals for logistic regression

2010-04-30 Thread Erik Iverson
jh556 wrote: I'm applying logistic regression to a moderate sized data set for which I believe Wald based confidence intervals on B coefficients are too conservative. Some of the literature recommends using confidence intervals based on the likelihood ratio in such cases, but I'm having diffic

[R] Likelihood ratio based confidence intervals for logistic regression

2010-04-30 Thread jh556
I'm applying logistic regression to a moderate sized data set for which I believe Wald based confidence intervals on B coefficients are too conservative. Some of the literature recommends using confidence intervals based on the likelihood ratio in such cases, but I'm having difficulty locating a

[R] likelihood profiles for multiple parameters

2010-03-24 Thread Benedikt Gehr, Institut für Evolutionsbiologie und Umweltwissenschaften
Hi I'm using mle2 for optimization of a multinomial likelihood. The model fit is not very good and I would like to look at the likelihood profiles. However I'm optimizing many parameters (~40) so using the function profile() takes forever and is not practical. How can I calculate approximate

Re: [R] likelihood ratio test between glmer and glm

2010-03-14 Thread Ben Bolker
Davnah Urbach dartmouth.edu> writes: > Thanks for this answer but does that mean that working > with the deviances is better? Or how else could I > evaluate the importance of my random terms? You should probably (a) search the archives of the r-sig-mixed-models mailing list and (b) ask this

Re: [R] likelihood ratio test between glmer and glm

2010-03-14 Thread Davnah Urbach
> Thanks for this answer but does that mean that working with the deviances is better? Or how else could I evaluate the importance of my random terms? Many thanks, Davnah > On Mar 14, 2010, at 8:12 PM, hadley wickham wrote: > >>> Based on a discussion found on the R mailing list but dating

Re: [R] likelihood ratio test between glmer and glm

2010-03-14 Thread hadley wickham
> Based on a discussion found on the R mailing list but dating back to 2008, I > have compared the log-likelihoods of the glm model and of the glmer model as > follows: > > lrt <- function (obj1, obj2){ > L0 <- logLik(obj1) > L1 <- logLik(obj2) > L01 <- as.vector(- 2 * (L0 - L1)) > df <- attr(L1,

[R] likelihood ratio test between glmer and glm

2010-03-14 Thread Davnah Urbach
I am currently running a generalized linear mixed effect model using glmer and I want to estimate how much of the variance is explained by my random factor. summary(glmer(cbind(female,male)~date+(1|dam),family=binomial,data= liz3")) Generalized linear mixed model fit by the Laplace approximatio

[R] Likelihood Optimization With Categorical Variables

2010-03-12 Thread Dr. Federico Andreis
Dear all, I have the following problem: I have been using the routine "optim" in order to maximize a joint likelihood (basically a mixture with modeled weights) with quantitative variables..so far so good. Now I need to plug into the model a categorical variable (namely, age classes). Obviousl

[R] likelihood

2010-03-08 Thread Ashta
Hi all, Does any one know how to write the likelihood function for Poisson distribution in R when P(x=0). For normal case, it an be written as follows, n * log(lambda) - lambda * n * mean(dat) Any help is highly appreciated Ashta

Re: [R] Likelihood Ratio Tests

2010-01-04 Thread Peter Dalgaard
Jim Silverton wrote: Is there any package available in R to do the following hypothesis tests? Testing the means of two Poissons (equivalent to the difference of two proportions) Testing the equality of two proportions from binomials Testing the equality of proprtions of two negative binomials (

Re: [R] Likelihood Ratio Tests

2010-01-03 Thread Jim Silverton
Is there any package available in R to do the following hypothesis tests? Testing the means of two Poissons (equivalent to the difference of two proportions) Testing the equality of two proportions from binomials Testing the equality of proprtions of two negative binomials (both conditional and un

Re: [R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives

2009-08-02 Thread nikolay12
Thanks, I had a look at mlogit. It seems it does fit a multinomial logit regression but - just as nnet or VGAM are doing it - it has a function that tells you the fitted value, not the value that you have with a set of parameters (which might not be the optimal ones). Or am I wrong on this? Rong

Re: [R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives

2009-08-02 Thread nikolay12
Thanks for the book suggestion. I'll check it out tomorrow when the library opens up. Yes, it is a multilevel model, but its likelihood function is the sum of the likelihood functions for the individual levels (i.e. a simple multinomial logits) and some other terms (the priors). It is, essential

Re: [R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives

2009-08-02 Thread Ronggui Huang
You may refer to mlogit for the ordinary multinomial regression. As fas as I know, there are no functions for multilevel multinomial regression. Ronggui 2009/8/2 nikolay12 : > > Hi, > > I would like to apply the L-BFGS optimization algorithm to compute the MLE > of a multilevel multinomial Logist

Re: [R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives

2009-08-02 Thread markleeds
> School of Medicine > Johns Hopkins University > > Ph. (410) 502-2619 > email: [1]rvarad...@jhmi.edu > > > - Original Message - > From: nikolay12 <[2]nikola...@gmail.com> > Date: Sunday, August 2, 20

Re: [R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives

2009-08-02 Thread nikolay12
> > > - Original Message - > From: nikolay12 > Date: Sunday, August 2, 2009 3:04 am > Subject: [R] Likelihood Function for Multinomial Logistic Regression and > its partial derivatives > To: r-help@r-project.org > > >> Hi, >> >> I

Re: [R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives

2009-08-02 Thread Ravi Varadhan
Sunday, August 2, 2009 3:04 am Subject: [R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives To: r-help@r-project.org > Hi, > > I would like to apply the L-BFGS optimization algorithm to compute > the MLE > of a multilevel multinomial Lo

[R] Likelihood Function for Multinomial Logistic Regression and its partial derivatives

2009-08-02 Thread nikolay12
Hi, I would like to apply the L-BFGS optimization algorithm to compute the MLE of a multilevel multinomial Logistic Regression. The likelihood formula for this model has as one of the summands the formula for computing the likelihood of an ordinary (single-level) multinomial logit regression. S

[R] likelihood

2009-05-22 Thread Mark Bilton
I have a problem related to measuring likelihood between -an observed presence absence dataset (containing 0 or 1) -a predicted simulation matrix of the same dimensions (containing values from 0 to 1) This must be a common problem but I am struggling to find the answer in the literature. Withi

Re: [R] Likelihood of a ridge regression (lm.ridge)?

2009-03-18 Thread Ravi Varadhan
ys). Ravi. Ravi Varadhan, Ph.D. Assistant Professor, Division of Geriatric Medicine and Gerontology School of Medicine Johns Hopkins University Ph. (410) 502-2619 email: rvarad...@jhmi.edu - Original Message - From: joris meys Date: Tuesday, March 17, 2009 7:37 pm Subject: [R] Likel

[R] Likelihood of a ridge regression (lm.ridge)?

2009-03-17 Thread joris meys
Dear all, I want to get the likelihood (or AIC or BIC) of a ridge regression model using lm.ridge from the MASS library. Yet, I can't really find it. As lm.ridge does not return a standard fit object, it doesn't work with functions like e.g. BIC (nlme package). Is there a way around it? I would ca

Re: [R] Likelihood ratio test using R

2008-11-04 Thread C.H.
For the third one: ?anova.glm test=Chisq will be LRT. For the first two, you can have the answer from ordinary stat book. On Wed, Nov 5, 2008 at 1:11 PM, Maithili Shiva <[EMAIL PROTECTED]> wrote: > Hi! > > I am working on the Logistic Regression using R. My R script is as follows > > > ONS <-

[R] Likelihood ratio test using R

2008-11-04 Thread Maithili Shiva
Hi! I am working on the Logistic Regression using R. My R script is as follows ONS <- read.csv("ONS.csv",header = TRUE) ONS.glm <- glm(Y ~ Age1+Age2+Sex+Education+Profession+TimeInJob+ TimeInCurrentJob+OwnResidence+Dependents+ApplIncome+FamilyInco+IIR+FOIR+YearsAtBank+SavingsAccount+CurrentAcc

[R] Likelihood ratio test using R

2008-11-04 Thread Maithili Shiva
Hi! I am working on the Logistic Regression using R. My R script is as follows ONS <- read.csv("ONS.csv",header = TRUE) ONS.glm <- glm(Y ~ Age1+Age2+Sex+Education+Profession+TimeInJob+ TimeInCurrentJob+OwnResidence+Dependents+ApplIncome+FamilyInco+IIR+FOIR+YearsAtBank+SavingsAccount+CurrentAc

Re: [R] Likelihood between observed and predicted response

2008-09-22 Thread Ben Bolker
Christophe LOOTS ifremer.fr> writes: > > Thank you so much for your help. > > The function "dbinom" seems to work very well. > > However, I'm a bit lost with the "dnorm" function. > > Apparently, I have to compute the mean "mu" and the standard deviation > "sd" but what does it mean exactly?

[R] Likelihood between observed and predicted response

2008-09-22 Thread Christophe LOOTS
Thank you so much for your help. The function "dbinom" seems to work very well. However, I'm a bit lost with the "dnorm" function. Apparently, I have to compute the mean "mu" and the standard deviation "sd" but what does it mean exactly? I only have a vector of predicted response and a vector

Re: [R] Likelihood ratio test between glm and glmer fits

2008-07-19 Thread Göran Broström
This particular case with a random intercept model can be handled by glmmML, by bootstrapping the p-value. Best, Göran On Thu, Jul 17, 2008 at 1:29 PM, Douglas Bates <[EMAIL PROTECTED]> wrote: > On Thu, Jul 17, 2008 at 2:50 AM, Rune Haubo <[EMAIL PROTECTED]> wrote: >> 2008/7/16 Dimitris Rizopoulo

Re: [R] Likelihood ratio test between glm and glmer fits

2008-07-17 Thread Douglas Bates
On Thu, Jul 17, 2008 at 2:50 AM, Rune Haubo <[EMAIL PROTECTED]> wrote: > 2008/7/16 Dimitris Rizopoulos <[EMAIL PROTECTED]>: >> well, for computing the p-value you need to use pchisq() and dchisq() (check >> ?dchisq for more info). For model fits with a logLik method you can directly >> use the foll

Re: [R] Likelihood ratio test between glm and glmer fits

2008-07-17 Thread Rune Haubo
2008/7/16 Dimitris Rizopoulos <[EMAIL PROTECTED]>: > well, for computing the p-value you need to use pchisq() and dchisq() (check > ?dchisq for more info). For model fits with a logLik method you can directly > use the following simple function: > > lrt <- function (obj1, obj2) { >L0 <- logLik(

Re: [R] Likelihood ratio test between glm and glmer fits

2008-07-16 Thread Dimitris Rizopoulos
well, for computing the p-value you need to use pchisq() and dchisq() (check ?dchisq for more info). For model fits with a logLik method you can directly use the following simple function: lrt <- function (obj1, obj2) { L0 <- logLik(obj1) L1 <- logLik(obj2) L01 <- as.vector(- 2 *

[R] Likelihood ratio test between glm and glmer fits

2008-07-16 Thread COREY SPARKS
Dear list, I am fitting a logistic multi-level regression model and need to test the difference between the ordinary logistic regression from a glm() fit and the mixed effects fit from glmer(), basically I want to do a likelihood ratio test between the two fits. The data are like this: My outc

Re: [R] Likelihood between observed and predicted response

2008-05-14 Thread Ben Bolker
Christophe LOOTS ifremer.fr> writes: > > Hi, > > I've two fitted models, one binomial model with presence-absence data > that predicts probability of presence and one gaussian model (normal or > log-normal abundances). > > I would like to evaluate these models not on their capability of > a

[R] Likelihood between observed and predicted response

2008-05-13 Thread Christophe LOOTS
Hi, I've two fitted models, one binomial model with presence-absence data that predicts probability of presence and one gaussian model (normal or log-normal abundances). I would like to evaluate these models not on their capability of adjustment but on their capability of prediction by calcu

[R] Likelihood ratio test for competing risks regression

2008-02-03 Thread Brant Inman
R-helpers: I have a question regarding the crr function of the cmprsk package for performing competing risks regression. Specifically, I was wondering if the standard likelihood ratio test for a categorical covariate applies. For example: # Make up a fake

Re: [R] Likelihood optimization numerically

2008-01-27 Thread Mohammad Ehsanul Karim
Dear List, Probably i am missing something important in optimize: llk.1st <- function(alpha){ x <- c(20.0, 23.9, 20.9, 23.8, 25.0, 24.0, 21.7, 23.8, 22.8, 23.1, 23.1, 23.5, 23.0, 23.0) n <- length(x) llk1 <- -n*log(gamma(alpha)) - n*alpha*log(sum(x)/(n*alpha)) + (alpha - 1)*(sum(log(x))) - (su

Re: [R] Likelihood optimization numerically

2008-01-26 Thread Bill.Venables
: r-help@r-project.org Subject: [R] Likelihood optimization numerically Dear List, I am not sure how should i optimize a log-likelihood numerically: Here is a Text book example from Statistical Inference by George Casella, 2nd Edition Casella and Berger, Roger L. Berger (2002, pp. 355, ex. 7.4 #

[R] Likelihood optimization numerically

2008-01-26 Thread Mohammad Ehsanul Karim
Dear List, I am not sure how should i optimize a log-likelihood numerically: Here is a Text book example from Statistical Inference by George Casella, 2nd Edition Casella and Berger, Roger L. Berger (2002, pp. 355, ex. 7.4 # 7.2.b): data = x = c(20.0, 23.9, 20.9, 23.8, 25.0, 24.0, 21.7, 23.8, 22

Re: [R] likelihood from test result

2008-01-10 Thread Matthias Kohl
Dear David, no, distrTEst won't help. It has a different intention. We are currently working on a new package "distrMod" (cf. https://r-forge.r-project.org/projects/distrmod/) which sometime might have such a functionality. Best, Matthias David Bickel wrote: > Is there any automatic mechanism f

Re: [R] likelihood from test result

2008-01-09 Thread Peter Dalgaard
David Bickel wrote: > Is there any automatic mechanism for extracting a likelihood or test > statistic distribution (PDF or CDF) from an object of class "htest" or > from another object of a general class encoding a hypothesis test > result? > > I would like to have a function that takes "x", an ob

Re: [R] likelihood from test result

2008-01-09 Thread Gabor Grothendieck
You could create an S3 generic that does it. That is not initially any less work than the if statement but if you add new distribution no existing code need be modified. Just add a new method for each distribution to be supported: getDistr <- function(x) { .Class <- names(x$value$statist

[R] likelihood from test result

2008-01-09 Thread David Bickel
Is there any automatic mechanism for extracting a likelihood or test statistic distribution (PDF or CDF) from an object of class "htest" or from another object of a general class encoding a hypothesis test result? I would like to have a function that takes "x", an object of class "htest", as its o

Re: [R] Likelihood ratio test for proportional odds logistic regression

2008-01-05 Thread Prof Brian Ripley
On Sat, 5 Jan 2008, xinyi lin wrote: > Hi, > > I want to do a global likelihood ratio test for the proportional odds > logistic regression model and am unsure how to go about it. I am using > the polr() function in library(MASS). > > 1. Is the p-value from the likelihood ratio test obtained by > a

[R] Likelihood ratio test for proportional odds logistic regression

2008-01-05 Thread xinyi lin
Hi, I want to do a global likelihood ratio test for the proportional odds logistic regression model and am unsure how to go about it. I am using the polr() function in library(MASS). 1. Is the p-value from the likelihood ratio test obtained by anova(fit1,fit2), where fit1 is the polr model with o

Re: [R] Likelihood ration test on glm

2007-09-21 Thread Charles C. Berry
On Fri, 21 Sep 2007, Wensui Liu wrote: > chris, > as long as you know the log likelihood functions and the # of > parameters in both models, a pencil and a piece of paper should be > enough to calculate LR test. True enough for the LR statistic. Or follow the instructions in the _posting guide_

Re: [R] Likelihood ration test on glm

2007-09-21 Thread Wensui Liu
chris, as long as you know the log likelihood functions and the # of parameters in both models, a pencil and a piece of paper should be enough to calculate LR test. On 9/21/07, Chris Elsaesser <[EMAIL PROTECTED]> wrote: > I would like to try a likelihood ratio test in place of waldtest. > Ideally

Re: [R] Likelihood ration test on glm

2007-09-21 Thread Kevin E. Thorpe
Chris Elsaesser wrote: > I would like to try a likelihood ratio test in place of waldtest. > Ideally I'd like to provide two glm models, the second a submodel of the > first, in the style of lrt > (http://www.pik-potsdam.de/~hrust/tools/farismahelp/lrt.html). [lrt > takes farimsa objects] > > Does

[R] Likelihood ration test on glm

2007-09-21 Thread Chris Elsaesser
I would like to try a likelihood ratio test in place of waldtest. Ideally I'd like to provide two glm models, the second a submodel of the first, in the style of lrt (http://www.pik-potsdam.de/~hrust/tools/farismahelp/lrt.html). [lrt takes farimsa objects] Does anyone know of such a likelihood rat