search for: dichotomize

Displaying 20 results from an estimated 185 matches for "dichotomize".

2008 Aug 06
1
Correlation dichotomous factor, continous (numerical) and ordered factor
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 correlation between every pair of my variables, because I would like to perform a logistic regression (glm())
2007 Aug 07
2
GLMM: MEEM error due to dichotomous variables
I am trying to run a GLMM on some binomial data. My fixed factors include 2 dichotomous variables, day, and distance. When I run the model: modelA<-glmmPQL(Leaving~Trial*Day*Dist,random=~1|Indiv,family="binomial") I get the error: iteration 1 Error in MEEM(object, conLin, control$niterEM) : Singularity in backsolve at level 0, block 1 >From looking at previous help
2011 Aug 05
1
Dichotomous variables
Hi everyone, Have sample of items for each one, a set of 20 dichotomous (absent-present) variables are expressed. I'm trying to understand how to explore the co-occurence of each variable. Read some papers concerning smallest space analysis, but it does not seems implemented in any R package (and my protamming skills are =0). Non metric MDS gives error messages, probably because of the
2006 Jun 28
1
Simulate dichotomous correlation matrix
...0 0.2913552 0.2204097 PHQCUT2T 0.1913139 0.2913552 1.0000000 0.1803987 ALCCUTT2 0.1917923 0.2204097 0.1803987 1.0000000 Where the prevalence for each variable is: > prevvals=c(0.26,0.10,0.09,0.10) I can use the mvrnorm function in MASS to create a matrix containing random normal variables and dichotomize these variables into 0,1; however, this is a less than ideal solution as my observed correlation matrix is downwardly biased and the amount of the bias is related to the prevalence of each variable. Thanks, Paul D. Bliese Heidelberg, Germany COMM: +49-6221-172626
2016 Apr 16
2
Problem: No p-value for a point-baserial correlation with R
Dear community I'm pretty new to R and I'm trying to do a Point-baserial correlation for a nominal dichotomous variable with a interval scaled variable. It works fine, but the output just shows me the correlation and nothing else (p-Value would be important). I tried it with the following codes: - biseral.cor() - cor.biseral() - I also tried a polyserial() I've found on this
2005 Oct 10
1
SEM with dichotomous indicators
Hello, I'd like to know if there is a way to fit a Structural equation model with dichotomous indicators (ex: problem with a phone solved/ or not) having effects on a ordinal variable. How I do that using R? Do you have an example with the code in R that you can send to me? Thanks a lot! Renata Estrella UFRJ, Brasil, Rio de Janeiro Renata Leite Estrella Assistente de
2009 Jun 14
1
estimate the reliability of a scale with dichotomous items
hi, How can I compute a reliability score of a scale consisting only of dichotomous items? thanks for any help!
2005 Sep 27
1
Simulate phi-coefficient (correlation between dichotomous vars)
...corr = ", cor(x, y), "\n") return(y) } X<-rnorm(100) #a constant vector Y1<-sample.cor(X,.30) # a new vector that correlates with X .30 Y2<-sample.cor(X,.45) # a second vector that correlates with X .45 I can, of course, have X be a vector of zeros and ones, and I can dichotomize Y1 and Y2, but the program always returns a phi-coefficient correlation lower than the continuous correlation. Mathematically, I guess this is expected because the phi-coefficient is partially a function of the percentage of positive responses. This, in turn, explains Pearson's (1900) interes...
2007 May 08
3
ordered logistic regression with random effects. Howto?
I'd like to estimate an ordinal logistic regression with a random effect for a grouping variable. I do not find a pre-packaged algorithm for this. I've found methods glmmML (package: glmmML) and lmer (package: lme4) both work fine with dichotomous dependent variables. I'd like a model similar to polr (package: MASS) or lrm (package: Design) that allows random effects. I was
2023 Nov 03
1
I need to create new variables based on two numeric variables and one dichotomize conditional category variables.
...39; loop. Regards, Jorgen Harmse. ------------------------------ Message: 8 Date: Fri, 3 Nov 2023 11:10:49 +1030 From: "Md. Kamruzzaman" <mkzaman.m at gmail.com> To: r-help at r-project.org Subject: [R] I need to create new variables based on two numeric variables and one dichotomize conditional category variables. Message-ID: <CAGbxoeGjsxZKQ6qijEMq-X-5doqnQQS1jjPDDrGT6hH5xWqOKQ at mail.gmail.com> Content-Type: text/plain; charset="utf-8" Hello Everyone, I have three variables: Waist circumference (WC), serum triglyceride (TG) level and gender. Waist ci...
2009 Jan 12
3
polychoric correlation: issue with coefficient sign
Hello, I am running polychoric correlations on a dataset composed of 12 ordinal and binary variables (N =384), using the polycor package. One of the association (between 2 dichotomous variables) is very high using the 2-step estimate (0.933 when polychoric run only between the two variables; but 0.801 when polychoric run on the 12 variables). The same correlation run with ML estimate returns a
2023 Nov 03
2
I need to create new variables based on two numeric variables and one dichotomize conditional category variables.
...-----Original Message----- From: R-help <r-help-bounces at r-project.org> On Behalf Of Jorgen Harmse via R-help Sent: Friday, November 3, 2023 11:56 AM To: r-help at r-project.org; mkzaman.m at gmail.com Subject: Re: [R] I need to create new variables based on two numeric variables and one dichotomize conditional category variables. df$LAP <- with(df, ifelse(G=='male', (WC-65)*TG, (WC-58)*TG)) That will do both calculations and merge the two vectors appropriately. It will use extra memory, but it should be much faster than a 'for' loop. Regards, Jorgen Harmse. ------------...
2011 Jun 14
1
predictive logistic model cell-biology, non-dichotomous data
Hi everyone, I would like to fit a predictive model to my data in order to compare absorbance readings to a toxin standard. This data was obtained by exposing red blood cells to different toxin concentrations, which lead to the lysis of the red blood cells, increasing the absorbance (hemoglobin is freed). The data has a sigmoid shape (see below), so I thought about fitting a logistic model to the
2002 May 23
1
Multilevel model with dichotomous dependent variable
Greetings- I'm working with data that are multilevel in nature and have a dichotomous outcome variable (presence or absence of an attribute). As far as I can tell from reading archives of the R and S lists, as well as Pinheiro and Bates and Venables and Ripley, - nlme does not have the facility to do what amounts to a mixed-effects logistic regression. - The canonical alternative is
2023 Nov 03
1
[EXTERNAL] RE: I need to create new variables based on two numeric variables and one dichotomize conditional category variables.
...gt; Date: Friday, November 3, 2023 at 16:12 To: Jorgen Harmse <JHarmse at roku.com>, r-help at r-project.org <r-help at r-project.org>, mkzaman.m at gmail.com <mkzaman.m at gmail.com> Subject: [EXTERNAL] RE: [R] I need to create new variables based on two numeric variables and one dichotomize conditional category variables. Just a minor point in the suggested solution: df$LAP <- with(df, ifelse(G=='male', (WC-65)*TG, (WC-58)*TG)) since WC and TG are not conditional, would this be a slight improvement? df$LAP <- with(df, TG*(WC - ifelse(G=='male', 65, 58))) --...
2009 Jun 24
2
Boxplots: side-by-side
Dear R-sians.. I am trying to plot boxplots with side-by-side option.. I tried some of the posted suggestions and could not make it work due to unequal sizes of categories... e.g. weekly measured water depth values are categorized into 5 levels based on their values such measurement is again categorized into dichotomous levels - based on the result of a test I would like generate boxplot of
2008 Jul 27
2
Link functions in SEM
Is it possible to fit a structural equation model with link functions in R? I am trying to build a logistic-regression-like model in sem, because incorporating the dichotomous variables linearly seems inappropriate. Mplus can do something similar by specifying a 'link' parameter, but I would like to be able to do it in R, ofcourse. I have explored the 'sem' package from John Fox,
2012 Jun 09
1
combining different types of graphics (scatterplots, boxplots) using lattice
Dear R users: I have a continuous outcome variable and four predictors, two continuous and two dichotomous. i would like to use the lattice plot to create scatter plots for the continuous predictors and boxplots for the dichotomous predictors. with 4 continuous variables, this is what i have been doing: trial = rbind ( cbind ( cimt$ant.mean, cimt$age, 1 ), cbind ( cimt$ant.mean, cimt$sbp, 2 ),
2023 Mar 27
1
Displaying Dichotomous Variables as fractions in gtsummary Tables
I think questions about gtsummary are better addressed to that project. They have a link "Getting Help" on their web page; I'd start there: https://www.danieldsjoberg.com/gtsummary/SUPPORT.html Duncan Murdoch On 27/03/2023 2:19 p.m., Deramus, Thomas Patrick wrote: > Hi R Experts. > > Apologies if this has been shared elsewhere, but I haven't been able to find a
2023 Nov 06
0
I need to create new variables based on two numeric variables and one dichotomize conditional category
...ssage: 10 Date: Sat, 4 Nov 2023 01:08:03 -0400 From: <avi.e.gross at gmail.com> To: "'Jorgen Harmse'" <JHarmse at roku.com> Cc: <r-help at r-project.org> Subject: Re: [R] [EXTERNAL] RE: I need to create new variables based on two numeric variables and one dichotomize conditional category variables. Message-ID: <019a01da0edc$e41c39e0$ac54ada0$@gmail.com> Content-Type: text/plain; charset="utf-8" To be fair, Jordan, I think R has some optimizations so that the arguments in some cases are NOT evaluated until needed. So only one or the othe...