Hi Silvano: Could you tell me what "correlation=corSymm(form = ~ 1 |id)" represents? In our case, team is random effect, trt, pairs, grade, school are fixed effect, and each team is within school.
I still got the different results from both SAS and R. > unstruct <- gls(score~trt+pairs+grade+school, > test,correlation=corSymm(form = ~ 1 |StudentID), + weights=varIdent(form=~1|team), method="REML") I tried school instead of StudentID, but I got error. > unstruct <- gls(score~trt+pairs+grade+school, > test,correlation=corSymm(form = ~ 1 |school), + weights=varIdent(form=~1|team), method="REML") Error in vector("double", length) : vector size specified is too large Thanks for the help -- View this message in context: http://r.789695.n4.nabble.com/HLM-Model-tp3242999p3249518.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.