similar to: As.Factor with Logistic Regression

Displaying 20 results from an estimated 2000 matches similar to: "As.Factor with Logistic Regression"

2006 Jun 23
3
Interpreting as.factor
When I run a linear regression and include a variable in the regression with as.factor i.e. lm(y ~x +as.factor(x1) and i read the output as as.factor(x1)1.... as.factor(x1)2... etc. how do i interpret the estimate for each level? Is this simply to be regarded as a shift in the equation predicted by the intercept and independent variable x? jdr -- Justin Rapp 409 S. 22nd St. Apt. 1
2011 May 05
7
Draw a nomogram after glm
Hi all R users I did a logistic regression with my binary variable Y (0/1) and 2 explanatory variables. Now I try to draw my nomogram with predictive value. I visited the help of R but I have problem to understand well the example. When I use glm fonction, I have a problem, thus I use lrm. My code is: modele<-lrm(Y~L+P,data=donnee) fun<- function(x) plogis(x-modele$coef[1]+modele$coef[2])
2006 Jun 23
0
Testing for Significance Between Logistic Regressions
This is more of a statistics question with implementation implications. I have used R to calculate logistic regressions for various characterstics. I would now like to verify that the difference between a particular subset is significantly different from the logistic regression of the entire set. Example. I have a logistic regression containing every running back drafted between 1980-2000. I
2010 Jul 31
3
I have a problem
dear£º in the example£¨nomogram£©£¬I don't understand the meanings of the program which have been marked by red line.And how to compile the program(L <- .4*(sex=='male') + .045*(age-50) + (log(cholesterol - 10)-5.2)*(-2*(sex=='female') + 2*(sex=='male'))). n <- 1000 # define sample size set.seed(17) # so can reproduce the results age <- rnorm(n, 50, 10)
2010 Oct 04
2
i have aproblem --thank you
dear professor: thank you for your help,witn your help i develop the nomogram successfully. after that i want to do the internal validation to the model.i ues the bootpred to do it,and then i encounter problem again,just like that.(´íÎóÓÚerror to :complete.cases(x, y, wt) : ²»ÊÇËùÓеIJÎÊý¶¼Ò»Ñù³¤(the length of the augment was different)) i hope you tell me where is the mistake,and maybe i have
2005 Feb 03
2
logistic regression 3D-plot
Dear R-helpers, I tried to create a 3D surface showing the interaction between two continuous explanatory variables; the response variable is binary (0/1). The model is: model<-glm(incidence~sun*trees,binomial) then I used "wireframe" to create a 3D plot: xyz<-expand.grid(sun=seq(30,180,1),trees=seq(0,4000,10)) xyz$incidence<-as.vector(predict(model,xyz))
2010 Oct 04
1
I have aproblem about nomogram--thank you for your help
dear professor: I have a problem about the nomogram.I have got the result through analysing the dataset "exp2.sav" through multinominal logistic regression by SPSS 17.0. and I want to deveop the nomogram through R-Projject,just like this : > n<-100 > set.seed(10) > T.Grade<-factor(0:3,labels=c("G0", "G1", "G2","G3")) >
2010 Oct 06
2
A problem --thank you
dear:teacher i have a problem which about the polr()(package "MASS"), if the response must have 3 or more levels? and how to fit the polr() to 2 levels? thank you. turly yours [[alternative HTML version deleted]]
2005 Aug 22
1
How to add legend of plot.Design function (method=image)? (if (!.R.) )
Hi, When running z <- plot(fit, age=NA, cholesterol=NA, perim=boundaries, method='image') Legend(z, fun=plogis, at=qlogis(c(.01,.05,.1,.2,.3,.4,.5)), zlab='Probability') And after pointing the cursor to the plot() screen in R, I obtain the following message: Using function "locator(2)" to place opposite corners of image.legend Error in
2008 May 29
2
Troubles plotting lrm output in Design Library
Dear R-helpers, I'm having a problem in using plot.design in Design Library. Tho following example code produce the error: > n <- 1000 # define sample size > set.seed(17) # so can reproduce the results > age <- rnorm(n, 50, 10) > blood.pressure <- rnorm(n, 120, 15) > cholesterol <- rnorm(n, 200, 25) > sex <-
2005 Oct 29
2
RODBC Error
Hello, I'm using R 2.2.0 on a Mac and attempting to use the RODBC package to connect to a PostgreSQL server on the local network. I can't tell whether my problem is in R, or in ODBC setup. I got drivers from OpenLink, created a dsn and tested it using the iODBC application. then I load the RODBC package, use this code and get the following error. I tried with both the
2006 Jun 22
1
Strings to Numbers?
I am running the following command. for( i in 1:378){ for (j in 1:5) { *********Year [((i-1)*5)+j,1]<- yearly[i,2];********* Year [((i-1)*5)+j,2] <- j; Year [((i-1)*5)+j,3] <- yearly[i,(j+2)]; j <- (j+1); } i <- (i+1) } The array referenced yearly[i,2] contains conference names i.e. BIG12, SEC, BIG10. The loop executes fine except for the fact that
2018 Jan 03
1
summary.rms help
Dear All, using the example from the help of summary.rms library(rms) n <- 1000 # define sample size set.seed(17) # so can reproduce the results age <- rnorm(n, 50, 10) blood.pressure <- rnorm(n, 120, 15) cholesterol <- rnorm(n, 200, 25) sex <- factor(sample(c('female','male'), n,TRUE)) label(age) <- 'Age'
2002 Sep 13
1
design package (plot problems)
Hi, just making some experiments with design library i get an error if i want plot(fit) - show below from onlineHelp !? ..perhaps is here another mask problem?, but label from xtable which was my first problem is now off ! Thanks for advance & regards, Christian $ n <- 1000 # define sample size $ set.seed(17) # so can reproduce the results $ age <- rnorm(n, 50, 10)
2003 Oct 20
2
Samba 3 Production
Is anyone using Samba 3 in a production environment? If so what version and how stable is it? -- Bert Rapp North Trail RV Center 239.693.8200 __ There are 10 types of people in this world, those who understand binary and those who don't.
2009 Aug 21
1
Question about validating predicted probabilities
Hello, Frank was nice enough to point me to the val.prob function of the Design library. It creates a beautiful graph that really helps me visualize how well my model is predicting probabilities. By default, there are two lines on the graph 1) fitted logistic calibration curve 2) nonparametric fit using lowess Right now, the nonparametric line doesn't look very good. The
2010 Jul 29
1
I need the dataset--thank you
dear: I am a user of R project.And now ,I have a problem. I want to know what is the name of the datasets in the web page--"Draw a Nomogram Representing a Regression Fit" which come from the R-home(http://www.r-project.org/ Package rms version 3.0-0). And can you supply the dataset to me? wish for your help,thank you!
2012 May 02
1
scanning a data set for strings
Hello, I'm looking for what I'm sure is a quick answer. I'm working with a data set that looks like this: Week Game.ID VTm VPts HTm HPts Differential HomeWin 1 1 NFL_20050908_OAK at NE OAK 20 NE 30 10 FALSE 2 1 NFL_20050911_ARI at NYG ARI 19 NYG 42 23 FALSE 3 1
2010 Aug 14
1
How to add lines to lattice plot produced by rms::bplot
I have a plot produced by function bplot (package = rms) that is really a lattice plot (class="trellis"). It is similar to this plot produced by a very minor modification of the first example on the bplot help page: requiere(rms) n <- 1000 # define sample size set.seed(17) # so can reproduce the results age <- rnorm(n, 50, 10) blood.pressure <- rnorm(n, 120,
2012 May 03
1
overlapping confidence bands for predicted probabilities from a logistic model
Dear list, I'm a bit perplexed why the 95% confidence bands for the predicted probabilities for units where x=0 and x=1 overlap in the following instance. I've simulated binary data to which I've then fitted a simple logistic regression model, with one covariate, and the coefficient on x is statistically significant at the 0.05 level. I've then used two different methods to