[程式] R RANK不足

看板Statistics作者 (Mark)時間10年前 (2015/03/29 20:01), 編輯推噓0(003)
留言3則, 1人參與, 最新討論串1/1
------------------------------------------------------------------------ [軟體程式類別]: R [程式問題]: rank不足 [軟體熟悉度]: 新手(不到1個月) [問題敘述]: 因為我的應變樹是一個60*44的矩陣。當我跑summary(manova(fit)) 時顯示 residuals have rank 43 < 44 。而當我跑summary(fit)時卻變成每筆資料跑 一個迴歸。請問我到底錯在哪?? [程式範例]: setwd("C:\\Users\\user\\Documents") dat_names = list.files()[grep("csv", list.files())] dat = Reduce(cbind, lapply(dat_names, read.csv)) responseFileName = "活頁簿1.csv" f = as.formula(paste("cbind(", paste(names(read.csv(responseFileName, nrows = 1)), collapse = ","), ") ~ .")) fit = lm(f, dat) summary(manova(fit)) ----------------------------------------------------------------------------- -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 163.22.18.73 ※ 文章網址: https://www.ptt.cc/bbs/Statistics/M.1427630470.A.BEE.html

03/29 20:18, , 1F
沒講自變數的大小。
03/29 20:18, 1F

03/29 20:44, , 2F
自變數個數應該是16個,所以sample size不足造成man
03/29 20:44, 2F

03/29 20:44, , 3F
ova residual的自由度不足
03/29 20:44, 3F
文章代碼(AID): #1L5-c6lk (Statistics)