Professional Documents
Culture Documents
By
Introduction
Revisit my York 2001 critique Review Progress with SPSS since then Talk about the opportunities with R
Technical Content
Linear Mixed Models (Now fixed) Generalised Linear Models (Now fixed) Generalised Linear Mixed Models (Now in R) General Purpose MLE fitting ? (Now in R )
NB: Then Website referred to CNLR
GTDL:
TDL:
RR:
Parameter Estimates 95% Confidence Interval 95% Trimmed Range Parameter Estimate Std. Error Lower Bound Upper Bound Lower Bound Upper Bound b0 -1.629 .073 -1.771 -1.486 -1.772 -1.499 alpha -.065 .011 -.087 -.042 -.087 -.042
a,b Bootstrap
NLM R Results
Parameter Estimates 95% Confidence Interval 95% Trimmed Range Parameter Estimate Std. Error Lower Bound Upper Bound Lower Bound Upper Bound a,b b0 Bootstrap -1.629 .075 -1.782 -1.475 -1.765 -1.465 alpha -.065 .012 -.090 -.039 -.090 -.038 a. Based on 30 samples. b. Loss function value equals 2056.044. Parameter Estimates
95% Confidence Interval 95% Trimmed Range Parameter Estimate Std. Error Lower Bound Upper Bound Lower Bound Upper Bound a,b b0 Bootstrap -1.629 .073 -1.771 -1.486 -1.772 -1.499 alpha -.065 .011 -.087 -.042 -.087 -.042 a. Based on 1000 samples. b. Loss function value equals 2056.044.
Passing SPSS objects (eg data) to R Return R objects (eg results) to SPSS For SPSS users this is an immediate major advance
results2<- nlm()
spsspivottable.Display(results2,title="Results2",format=formatSpec.GeneralStat) END PROGRAM. BEGIN PROGRAM R.
results3<- nlm()
spsspivottable.Display(results3,title="Results3",format=formatSpec.GeneralStat) END PROGRAM. CBS, University of Limerick Assess, York, Nov 2009
Hessian Observed Information Fisher Information Covariance Matrix Covariance Matrix Vector of variances Vector of Std. Errors
() [Io()]
v() = diag[Io()
Input Parameters
# must set up extra before call loglikexp <- function(x, extra) { fi <- x lam <-exp(fi) # keep scalar hazard lam >0 ti <- extra[,1] # vector of survival times deltai <- extra[,2] # vector of censoring indicators loglike <- -sum(deltai*fi-lam*ti) } Return Value call result <- loglikexp(param, extra) result # displays loglike on console in R
CBS, University of Limerick Assess, York, Nov 2009
Go to Cran mirror & download R V2.5 and install Download R integration installer and documentation from www.spss.devcentral and install Read the R integration document first Run SPSS using blocked syntax files
Create a Consistent Programming Environment Support Object Orientated Language Encourage a Technical Development Group
Need to develop output interface Need to allow R graphical objects out or to chart editor Guidance on future SPSS development strategies for R integration Progress Indeed!!