Advertisement
Guest User

Untitled

a guest
Apr 27th, 2015
220
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.03 KB | None | 0 0
  1. # Linearly regress readk on the interaction between stark and ethnicity
  2. read_int <- lm(readk ~ stark*ethnicity, data=STAR)
  3. read_int
  4. # Bootstrapped standard errors
  5. #read_int_boot <- replicate(500, est.coefs.lm(read_int, resample.cases(STAR)))
  6.  
  7. #merge(read_int_boot)
  8. #merge(x, y, by="row.names")
  9. #Reduce(function(x, y) merge(x, y, by="row.names"), read_int_boot)
  10. #Reduce(function(x, y) {merge(x, y, by="row.names")}, read_int_boot)
  11. #Reduce(function(...) merge(..., all=T), read_int_boot)
  12.  
  13. #dat <- as.data.frame(read_int_boot[[1]])
  14. #for(i in 2:length(read_int_boot)){
  15. # dat <- merge(dat, as.data.frame(read_int_boot[[i]]), by="row.names")
  16. #}
  17.  
  18. #library(reshape)
  19. #merge_all(read_int_boot)
  20.  
  21.  
  22. #rn <- rownames(df1)
  23. #l <- list(df1, df2, df3, df4)
  24. #dat <- l[[1]]
  25. #for(i in 2:length(l)) {
  26. # dat <- merge(dat, l[[i]], by= "row.names", all.x= F, all.y= F) [,-1]
  27. # rownames(dat) <- rn
  28. #}
  29.  
  30.  
  31.  
  32.  
  33. #read_int_se <- bootstrap.ses(read_int_boot[[500]])
  34.  
  35. #library(plyr)
  36. #yo <- join_all(as.data.frame(read_int_boot), by="rn", type="inner")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement