search for: gender

Displaying 20 results from an estimated 578 matches for "gender".

Did you mean: sender
2006 Feb 15
1
no convergence using lme
Hi. I was wondering if anyone might have some suggestions about how I can overcome a problem of "iteration limit reached without convergence" when fitting a mixed effects model. In this study: Outcome is a measure of heart action Age is continuous (in weeks) Gender is Male or Female (0 or 1) Genotype is Wild type or knockout (0 or 1) Animal is the Animal ID as a factor Gender.Age is Gender*Age Genotype.Age is Genotype*Age Gender.Genotype.Age is Gender*Genotype*Age If I have the intercept (but not the slope) as a random effect the fit converges OK fi...
2008 Dec 03
2
changing colnames in dataframes
dear all, I'm building new dataframes from bigger one's using e.g. columns F76, F83, F90: JJ<-data.frame( c( as.character(rep( gender,3))) , c( F76,6- F83, F90) ) Looking into JJ one has: c.as.character.rep.gender..8... c.6...F73..F78..F79..F82..6...F84..F94..F106..F109 1 w 2 2 w 3 3...
2005 Apr 19
1
How to make combination data
Dear R-user, I have a data like this below, age <- c("young","mid","old") married <- c("no","yes") income <- c("low","high","medium") gender <- c("female","male") I want to make some of combination data like these, age.income.dat <- expand.grid(age, married[-c(2)], income, gender[-c(2)]) age.income.dat age.married.dat <- expand.grid(age, married, income[-c(2:3)], gender[-c(2)]) age.married.dat...
2006 Jun 04
1
Nested and repeated effects together?
Dear R people, I am having a problem with modeling the following SAS code in R: Class ID Gr Hemi Region Gender Model Y = Gr Region Hemi Gender Gr*Hemi Gr*Region Hemi*Region Gender*Region Gender*Hemi Gr*Hemi*Region Gender*Hemi*Region Gr*Gender*Hemi*Region Random Intercept Region Hemi /Subject = ID (Gr Gender) I.e., ID is a random effect nested in Gr and Gender, leading to ID-specific Intercept, Region an...
2009 Sep 08
2
Very basic question regarding plot.Design...
Hello ALL! I have a problem to plot factor (lets say gender) as a line, or at least both line and point, from ols model: ols1 <- ols(Y ~ gender, data=dat, x=T, y=T) plot(ols1, gender=NA, xlab="gender", ylab="Y", ylim=c(5,30), conf.int=FALSE) If I convert gender into discrete numeric predictor, and use forceLines=TRUE, plot is not n...
2010 Jan 21
1
Simple effects with Design / rms ols() function
Hi everyone, I'm having some difficulty getting "simple effects" for the ols() function in the rms package. The example below illustrates my difficulty -- I'll be grateful for any help. #make up some data exD <- structure(list(Gender = structure(c(1L, 2L, 1L, 2L, 1L, 1L, 1L, 2L, 1L, 2L, 2L, 2L, 1L, 2L), .Label = c("F", "M"), class = "factor"), UCS = c(3.11111111111111, 3.5, 3.77777777777778, 2.875, 3.55555555555556, 2.44444444444444, 2.57142857142857, 3.11111111111111, 3.28571428571429,...
2008 Nov 17
5
how to calculate another vector based on the data from a combination of two factors
Hi, I have a data set similar to the following State Gender Quantity TX Male 1 NY Female 2 TX Male 3 NY Female 4 I need to calculate cumulative sum of the quantity by State and Gender. The expected output is State Gender Quantity CumQuantity TX Male 1 1 TX Male 3 4 NY Female 2 2 NY Female 4 6 I highly appreciate if someone can give me some hints on solv...
2001 Oct 16
4
two way ANOVA with unequal sample sizes
Hi, I am trying a two way anova with unequal sample sizes but results are not as expected: I take the example from Applied Linear Statistical Models (Neter et al. pp889-897, 1996) growth rate gender bone development 1.4 1 1 2.4 1 1 2.2 1 1 2.4 1 2 2.1 2 1 1.7 2 1 2.5 2 2 1.8 2 2 2 2 2 0.7 3 1 1.1 3 1 0.5 3 2 0.9 3 2 1.3 3 2 expected results are source of variation SS df MS F gender 0.12 1 0.12 0.74 bone development 4.1897 2 2.0949 12.89** intera...
2005 Feb 28
5
Using session data in model
Hi, I want to use my some session data when I validate som data in the model. The specific problem I have is that I present different forms data based on gender, and then dependent of the gender, there''s different fields that needs validation. I''m wondering what''s the preffered way of doing this. The session data is not present in the model, i.e: class Myclass < ActiveRecord::Base belongs_to :member def validate error...
2006 Nov 25
3
Multiple Conditional Tranformations
...#39;m learning R and I'm stuck on a basic concept: how to specify a logical condition once and then perform multiple transformations under that condition. The program below is simplified to demonstrate the goal. Its results are exactly what I want, but I would like to check the logical state of gender only once and create both (or any number of) scores at once. mystring<- ("id,group,gender,q1,q2,q3,q4 01,1,f,2,2,5,4 02,2,f,2,1,4,5 03,1,f,2,2,4,4 04,2,f,1,1,5,5 05,1,m,4,5,4, 06,2,m,5,4,5,5 07,1,m,3,3,4,5 08,2,m,5,5,5,4") mydata<-read.table(textConnection(mystring)...
2007 Mar 08
1
how to assign fixed factor in lm
Hi there, > Value=c(709,679,699,657,594,677,592,538,476,508,505,539) > Lard=rep(c("Fresh","Rancid"),each=6) > Gender=rep(c("Male","Male","Male","Female","Female","Female"),2) > Food=data.frame(Value,Lard,Gender) > Food Value Lard Gender 1 709 Fresh Male 2 679 Fresh Male 3 699 Fresh Male 4 657 Fresh Female 5 594 Fresh...
2007 Apr 02
1
?Bug: '&&' and '&' give different results?
"&&" seems to behave strangely and gives different results from "&" e.g. in a data frame selection (regardless whether terms are bracketed)? ===========Script======================= test=data.frame(gender=c("F","M","M","F","F"),side=c("R","L","R","L","R")) test test[test$gender=="F" & test$side=="R",] test[test$gender=="F" && test$side=="R",] ======...
2010 Mar 06
2
Plot interaction in multilevel model
I am trying to plot an interaction in a multilevel model. Here is some sample data. In the following example, it is longitudinal (i.e., repeated measures), so the outcome, score (at each of the three time points), is nested within the individual. I am interested in the interaction between gender and happiness predicting score. id <- c(1,1,1,2,2,2,3,3,3) age <- c(10,15,20,10,15,20,10,15,20) gender <- c(1,1,1,0,0,0,1,1,1) happiness <- c(50,30,25,70,65,80,70,40,60) score <- c(180,140,110,240,220,280,150,140,130) mydata <- data.frame(id,age,gender,happiness,score) I am loo...
2007 Jun 21
1
Result depends on order of factors in unbalanced designs (lme, anova)?
Dear R-Community! For example I have a study with 4 treatment groups (10 subjects per group) and 4 visits. Additionally, the gender is taken into account. I think - and hope this is a goog idea (!) - this data can be analysed using lme as below. In a balanced design everything is fine, but in an unbalanced design there are differences depending on fitting y~visit*treat*gender or y~gender*visit*treat - at least with anova (see...
2006 Nov 05
3
struggling to plot subgroups
Hi Folks, I have data that looks like this: freq gender xBar 1000 m 2.32 1000 f 3.22 2000 m 4.32 2000 f 4.53 3000 m 3.21 3000 f 3.44 4000 m 4.11 4000 f 3.99 I want to plot two lines (with symbols) for the two groups "m" and "f". I have tried the following: plot(xBar[gender=="m"]~freq[gender=="f&quo...
2013 Jan 31
2
Help with multiple barplots
Hello: I need to create a six barplots from data that looks pretty close to what appears below. There are two grouping variables (age and gender) and three dependent variables for each grouping variables. I'm not really familiar with trellis graphics, perhaps there is something that can do what I need there, i don't know. The thing is: I *need* these to appear on one row, with some way of differentiating between the three barplot...
2011 Jan 23
2
Creating subsets of a matrix
Hello, Say I have 2 columns, bmi and gender, the first being all the values and the second being male or female. How would I subset this into males only and females only? I have searched these fora and read endlessly about select[] and split() functions but to no avail. Also the table is not ordered. bmi gender -> bmi ge...
2005 Aug 05
1
contrast {Design} question
All, I have been trying to get the following code to work: A.quantiles <- quantile(foo.frame$A, probs = seq(from = 0.05, to = 0.95, by = 0.05)) base.quantiles <- quantile(Efficacy205$BASELINE_RANK, probs = seq(from = 0.05, to = 0.95, by = 0.05)) gender <- levels(Efficacy205$GENDER) contrast.1 <- contrast(Model.1, list(TPCODE= 'A', AGE = age.quantiles, BASELINE_RANK = base.quantiles, GENDER = gender), list(TPCODE = 'D', AGE = age.quantiles,...
2013 Jan 04
2
"By" function Frame Conversion (with Multiple Indices)
Hello, I have the following dataset. Please note that there are missing values on records 4 and 5: id,age,weight,height,gender 1,22,180,72,m 2,13,100,67,f 3,5,40,40,f 4,6,42,,f 5,12,98,66, 6,50,255,60,m I'm using the "By" function like this: list1 <- by(dataset[c("weight", "height")], dataset[c("age", "gender")], colMeans,...
2008 May 25
1
marginality principle / selecting the right type of SS for an interaction hypothesis
...a certain situational condition exists ("stereotype threat"). N = 160, 80 female & 80 male participants, 82 under stereotype threat and 78 not. I realize that it makes no sense to report/interpret a main effect of stereotype threat in the confirmed presence of the interaction effect GENDER:STTHREAT, because a main effect of stereotype threat would actually be caused by the interaction (an error-bar plot illustrating this can be found here if one scrolls a little downwars: http://myowelt.blogspot.com/2008/05/obtaining-same-anova-results-in-r-as-in.html) . I thus tend to use Type-II...