Displaying 20 results from an estimated 60000 matches similar to: "missing values in logistic regression"
2007 Nov 22
3
question about extreme value distribution
Hello,
I have a question about using extreme
value distribution in R.
I have two variables, X and Y, and have pairs
of points (X1,Y1),(X2,Y2), (X3,Y3) etc.
When I plot X against Y, it looks
like the maximum value of Y (for a particular X) is
correlated with X.
Indeed, when I bin the data by X-value into
equally sized bins, and test whether the maximum
value of Y for a bin is correlated with
2009 Nov 16
2
fitting a logistic regression with mixed type of variables
Hi,
I am trying to fit a logistic regression using glm, but my explanatory
variables are of mixed type: some are numeric, some are ordinal, some are
categorical, say
If x1 is numeric, x2 is ordinal, x3 is categorical, is the following formula
OK?
*model <- glm(y~x1+x2+x3, family=binomial(link="logit"), na.action=na.pass)*
*
*
*Thanks,*
*
*
*-Jack*
[[alternative HTML version
2009 Aug 03
1
min frequencies of categorical predictor variables in GLM
Hi,
Suppose a binomial GLM with both continuous as well as categorical
predictors (sometimes referred to as GLM-ANCOVA, if I remember
correctly). For the categorical predictors = indicator variables, is
then there a suggested minimum frequency of each level ? Would such a
rule/ recommendation be dependent on the y-side too ?
Example: N is quite large, a bit > 100. Observed however are
2010 Jun 30
3
Logistic regression with multiple imputation
Hi,
I am a long time SPSS user but new to R, so please bear with me if my
questions seem to be too basic for you guys.
I am trying to figure out how to analyze survey data using logistic
regression with multiple imputation.
I have a survey data of about 200,000 cases and I am trying to predict the
odds ratio of a dependent variable using 6 categorical independent variables
(dummy-coded).
2006 Sep 10
2
formatting data to be analysed using multinomial logistic regression (nnet)
I am looking into using the multinomial logistic regression option in the
nnet library and have two questions about formatting the data.
1. Can data be analysed in the following format or does it need to be
transformed into count data, such as the housing data in MASS?
Id Crime paranoia hallucinate toc disorg crimhist age
1 2 1 0 1 0 1 25
2 2 0 1 1 1 1 37
3 1 1 0 1 1 0 42
4 3 0
2011 Dec 01
2
how to get inflection point in binomial glm
Dear All,
I have a binomial response with one continuous predictor (d) and one
factor (g) (8 levels dummy-coded).
glm(resp~d*g, data, family=binomial)
Y=b0+b1*X1+b2*X2 ... b7*X7
how can I get the inflection point per group, e.g., P(d)=.5
I would be grateful for any help.
Thanks in advance,
Ren?
2010 Feb 18
1
logistic regression - what is being predicted when using predict - probabilities or odds?
Dear gurus,
I've analyzed a (fake) data set ("data") using logistic regression (glm):
logreg1 <- glm(z ~ x1 + x2 + y, data=data, family=binomial("logit"),
na.action=na.pass)
Then, I created a data frame with 2 fixed levels (0 and 1) for each predictor:
attach(data)
x1<-c(0,1)
x2<-c(0,1)
y<-c(0,1)
newdata1<-data.frame(expand.grid(x1,x2,y))
2009 Apr 07
1
Simulate binary data for a logistic regression Monte Carlo
Hello,
I am trying to simulate binary outcome data for a logistic regression Monte
Carlo study. I need to eventually be able to manipulate the structure of the
error term to give groups of observations a random effect. Right now I am
just doing a very basic set up to make sure I can recover the parameters
properly. I am running into trouble with the code below. It works if you
take out the object
2011 May 15
5
Question on approximations of full logistic regression model
Hi,
I am trying to construct a logistic regression model from my data (104
patients and 25 events). I build a full model consisting of five
predictors with the use of penalization by rms package (lrm, pentrace
etc) because of events per variable issue. Then, I tried to approximate
the full model by step-down technique predicting L from all of the
componet variables using ordinary least squares
2010 Nov 13
1
Define a glm object with user-defined coefficients (logistic regression, family="binomial")
Hi there,
I just don't find the solution on the following problem. :(
Suppose I have a dataframe with two predictor variables (x1,x2) and one
depend binary variable (y). How is it possible to define a glm object
(family="binomial") with a user defined logistic function like p(y) =
exp(a + c1*x1 + c2*x2) where c1,c2 are the coefficents which I define.
So I would like to do no
2010 Dec 29
1
logistic regression with response 0,1
Dear Masters,
first I'd like to wish u all a great 2011 and happy holydays by now,
second (here it come the boring stuff) I have a question to which I hope u
would answer:
I run a logistic regression by glm(), on the following data type
(y1=1,x1=x1); (y2=0,x2=x2);......(yn=0,xn=xn), where the response (y) is
abinary outcome on 0,1 amd x is any explanatory variable (continuous or not)
2007 Jul 12
1
mix package causes R to crash
Dear Professor Schaefer
I am experiencing a technical difficulty with your mix package.
I would appreciate it if you could help me with this problem.
When I run the following code, R 2.5.1 and R 2.6.0 crashes.
It's been tested on at least 2 windows machine and it is consistent.
Execution code it's self was coped from the help file of imp.mix.
Only thing I supplied was a fake dataset.
2006 Aug 31
3
what's wrong with my simulation programs on logistic regression
Dear friends,
I'm doing a simulation on logistic regression model, but the programs can't
work well,please help me to correct it and give some suggestions.
My programs:
data<-matrix(rnorm(400),ncol=8) #sample size is 50
data<-data.frame(data)
names(data)<-c(paste("x",1:8,sep="")) #8 independent variables,x1-x8;
#logistic regression model is
2008 Dec 18
3
Calculating Sensitivity, Specificity, and Agreement from Logistics Regression Model
Hi,
Assume I have a variable Y having two discrete values and two predictor variables x1 and x2.
I then do a logistic regression model fit as:
fit<-glm(Y~x1+x2,family=binomial). Are there functions in R than calculate the
Sensitivity, Specificity , and Agreement of the model "fit"?
Thanks
Meir
********************************************
Meir Preiszler - Research Engineer
I t
2010 Apr 04
2
logistic regression in an incomplete dataset
Dear all,
I want to do a logistic regression.
So far I've only found out how, in a dataset of complete cases.
I'd like to do logistic regression via max likelihood, using all the study
cases (complete and incomplete). Can you help?
I'm using glm() with family=binomial(logit).
If any covariate in a study case is missing then the study case is
dropped, i.e. it is doing a complete case
2006 Jul 18
1
Survey-weighted ordered logistic regression
Hi,
I am trying to fit a model with an ordered response variable (3 levels) and
13 predictor variables. The sample has complex survey design and I've used
'svydesign' command from the survey package to specify the sampling design.
After reading the manual of 'svyglm' command, I've found that you can fit a
logistic regression (binary response variable) by specifying the
2010 May 14
4
Categorical Predictors for SVM (e1071)
Dear all,
I have a question about using categorical predictors for SVM, using "svm"
from library(e1071). If I have multiple categorical predictors, should they
just be included as factors? Take a simple artificial data example:
x1<-rnorm(500)
x2<-rnorm(500)
#Categorical Predictor 1, with 5 levels
x3<-as.factor(rep(c(1,2,3,4,5),c(50,150,130,70,100)))
#Catgegorical Predictor
2004 Jun 09
1
testing effects of quantitative predictors on a categorical response variable
Hello,
I have a small statistics question, and
as I'm quite new to statistics and R, I'm not
sure if I'm doing things correctly.
I am looking at two quantitative
variables (x,y) that are correlated.
When I divide the data set according to a categorical
variable z, then x and y are more poorly correlated
when z = A than when z = B (see attached figure).
In fact x and y are two
2012 Oct 20
1
rms plot.Predict question: swapping x- and y- axis for categorical predictors
Hello all,
I'm trying to plot the effects of variables estimated by a regression model
fit individually, and for categorical predictors, the independent variable
shows up on the y-axis, with the dependent variable on the x-axis. Is there
a way to prevent this reversal?
Sample code with dummy data:
# make dummy data
set.seed(1)
x1 <- runif(200)
x2 <- sample(c(1,2),200, TRUE)
x3 <-
2004 Jul 20
3
regression slope
Hello,
I'm a newcomer to R so please
forgive me if this is a silly question.
It's that I have a linear regression:
fm <- lm (x ~ y)
and I want to test whether the
slope of the regression is significantly
less than 1. How can I do this in R?
I'm also interested in comparing the
slopes of two regressions:
fm1 <- lm (x ~ y)
fm2 <- lm (a ~ b)
and asking if the slope of fm1 is