Thanks very much; with your tips, I was able to get the nested ifelse statement
to work properly!
Courtney Benjamin
From: PIKAL Petr
Sent: Thursday, August 10, 2017 5:39 AM
To: Courtney Benjamin; r-help@r-project.org
Subject: RE: Creating New Variable
oach at trying to handle the NAs properly-returns an error
elsq2wbl$NONWBLRELJOB <- ifelse(elsq2wbl$PSWBL=="No" &
elsq2wbl$EVERRELJOB=="Yes",1,ifelse(is.na(elsq2wbl$PSWBL)&is.na(elsq2wbl$EVERRELJOB),NA,
ifelse(elsq2wbl$PSWBL!="No" & elsq2wbl$EVER
?Problem solved; I did not have the most updated version of R. When I updated
it and ran the code, all worked well again. Thanks very much for helping me
solve the mistake of an R novice!
Courtney Benjamin
Broome-Tioga BOCES
Automotive Technology II Teacher
Located at Gault Toyota
a.action=na.omit)
summary(Othpared)?
Any help in resolving this concern would be greatly appreciated.
Sincerely,
Courtney
Courtney Benjamin
Broome-Tioga BOCES
Automotive Technology II Teacher
Located at Gault Toyota
Doctoral Candidate-Educational Theory & Practice
State University of Ne
[,1:16], repweights =
elsq1ch[,18:217], weights = elsq1ch[,17], combined.weights = TRUE, type = "BRR")
elsq1ch_brr
allCColr <-
svyolr(F3ATTAINMENT~F1PARED+BYINCOME+F1RACE+F1SEX+F1RGPP2+F1HIMATH+F1RTRCC,design=subset(elsq1ch_brr,BYSCTRL==1&G10COHRT==1),na.action=na.omit)
?
is resulting in the qr.default error
CTE <-
svyglm(formula=F3ATTAINB~F1PARED+BYINCOME+F1RACE+F1SEX+F1RGPP2+F1HIMATH,family="binomial",design=elsq1ch_brr,subset=BYSCTRL==1&G10COHRT==1&F1RTRCC=="Academic",na.action=na.omit)
summary(CTE)
Courtney Benjamin
Broome-Tioga
-svrepdesign(variables = elsq1ch, repweights = elsq1ch[,18:217],
weights = elsq1ch[,17], combined.weights = TRUE, type = "BRR")
decilemodel<- svyglm(r~your_g, design=newdesign,subset=BYSCTRL==1&G10COHRT==1)
regTermTest(decilemodel, ~your_g)
Courtney Benjamin
Broome-
Thank you; I appreciate your advisement.
Courtney Benjamin
Broome-Tioga BOCES
Automotive Technology II Teacher
Located at Gault Toyota
Doctoral Candidate-Educational Theory & Practice
State University of New York at Binghamton
cbenj...@btboces.org<mailto:cbenj...@btboces.org>
indicate a poor model fit.
Sincerely,
Courtney
Courtney Benjamin
Broome-Tioga BOCES
Automotive Technology II Teacher
Located at Gault Toyota
Doctoral Candidate-Educational Theory & Practice
State University of New York at Binghamton
cbenj...@btboces.org<mailto:cbenj...@btboces.or
naming/specifying the new variables of r and g
properly
transform(elsq1ch,r=r,g=g)
elsq1ch_brr <- update(elsq1ch_brr,tag=g,tag=r)
#then:
decilemodel<- svyglm(r~g, design=newdesign)
regTermTest(decilemodel, ~g)
#is the F-adjusted mean residual test from the Archer Lemeshow paper
Thank you,
Courtney
Thank you, Anthony; it worked flawlessly.?
Courtney Benjamin
Broome-Tioga BOCES
Automotive Technology II Teacher
Located at Gault Toyota
Doctoral Candidate-Educational Theory & Practice
State University of New York at Binghamton
cbenj...@btboces.org<mailto:cbenj...@btboces.org>
for the predictors
allCC <-
svyglm(formula=F3ATTAINB~F1PARED+BYINCOME+F1RACE+F1SEX+F1RGPP2+F1HIMATH+F1RTRCC,family="binomial",design=elsq1ch_brr,subset=BYSCTRL==1&G10COHRT==1,na.action=na.omit)
summary(allCC)
Any guidance is greatly appreciated.?
Sincerely,
Courtney?
Courtney B
Thank you; I will do so.
Courtney Benjamin
Broome-Tioga BOCES
Automotive Technology II Teacher
Located at Gault Toyota
Doctoral Candidate-Educational Theory & Practice
State University of New York at Binghamton
cbenj...@btboces.org<mailto:cbenj...@btboces.org>
60
")
elsq1ch_brr
#Logistic regression call which yields a warning regarding svyrepdesign object
allCC
<-svyglm(formula=F3ATTAINB~F1PARED+BYINCOME+F1RACE+F1SEX+F1RGPP2+F1HIMATH+F1RTRCC,family="binomial",design=elsq1ch_brr,subset=BYSCTRL==1&G10COHRT==1,na.action=na.exclude)
summar
el of two of my predictor
variables (BYINCOME & F1HIMATH) were changed.
Courtney Benjamin
Broome-Tioga BOCES
Automotive Technology II Teacher
Located at Gault Toyota
Doctoral Candidate-Educational Theory & Practice
State University of New York at Binghamton
cbenj...@btboces.org<mailto
es.1252
#attached base packages:
# [1] grid stats graphics grDevices utils datasets methods
base
#other attached packages:
#[1] survey_3.31-2 survival_2.39-4 Matrix_1.2-6RCurl_1.95-4.8
bitops_1.0-6
#loaded via a namespace (and not attached):
#[1] tools_3.3.1 splines
To: Courtney Benjamin
Cc: r-help@r-project.org
Subject: RE: Svyglm Error in Survey Package
Dear Courtney,
You're confusing a function call, na.action(na.omit), with an argument
specification, na.action=na.omit (and, in any event, there is no na.action()
function). But you don't have
TRL==1 & G10COHRT==1)
dim(samp1)
mc1 <- svyglm(F3ATTAINMENT~F1SES2QU+F1RGPP2,elsq1ch_brr,subset=samp1,na.action)
summary(mc1)?
Both attempts resulted in the same error stated above. Any advisement in how
to resolve this error would be greatly appreciated.
Sincerely,
Courtney Benjamin
?
(file="els-Q1-04-21-16.dat", header = TRUE, sep = "\t", quote = "\"", dec =".")
or I am not specifying some detail that is required to manually assign labels
to the values of the variables.?
Courtney Benjamin
Broome-Tioga BOCES
Automotiv
19 matches
Mail list logo