SHARE
TWEET

Untitled

a guest Jan 22nd, 2019 60 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. N <- 50
  2. df  <- data.frame(
  3.   LA1 = sample(1:10, size = N, replace = TRUE),
  4.   LA2 = sample(1:10, size = N, replace = TRUE),
  5.   LA3 = sample(1:10, size = N, replace = TRUE),
  6.   LA4 = sample(1:10, size = N, replace = TRUE),
  7.   LA5 = sample(1:10, size = N, replace = TRUE),
  8.   LA6 = sample(1:10, size = N, replace = TRUE),
  9.   LA7 = sample(1:10, size = N, replace = TRUE),
  10.   LA8 = sample(1:10, size = N, replace = TRUE),
  11.   LAY = sample(1:10, size = N, replace = TRUE),
  12.  
  13.   UF1 = sample(1:10, size = N, replace = TRUE),
  14.   UF2 = sample(1:10, size = N, replace = TRUE),
  15.   UF3 = sample(1:10, size = N, replace = TRUE),
  16.   UF4 = sample(1:10, size = N, replace = TRUE),
  17.   UF5 = sample(1:10, size = N, replace = TRUE),
  18.   UF6 = sample(1:10, size = N, replace = TRUE),
  19.   UFY = sample(1:10, size = N, replace = TRUE),
  20.  
  21.   EK1 = sample(1:10, size = N, replace = TRUE),
  22.   EK2 = sample(1:10, size = N, replace = TRUE),
  23.   EK3 = sample(1:10, size = N, replace = TRUE),
  24.   EK4 = sample(1:10, size = N, replace = TRUE),
  25.   EK5 = sample(1:10, size = N, replace = TRUE),
  26.   EK6 = sample(1:10, size = N, replace = TRUE),
  27.   EK7 = sample(1:10, size = N, replace = TRUE),
  28.   EK8 = sample(1:10, size = N, replace = TRUE),
  29.   EK9 = sample(1:10, size = N, replace = TRUE),
  30.   EK10 = sample(1:10, size = N, replace = TRUE),
  31.   EK11 = sample(1:10, size = N, replace = TRUE),
  32.   EK12 = sample(1:10, size = N, replace = TRUE),
  33.   EKY = sample(1:10, size = N, replace = TRUE),
  34.  
  35.   Z1 = sample(1:10, size = N, replace = TRUE),
  36.   Z2 = sample(1:10, size = N, replace = TRUE),
  37.   Z3 = sample(1:10, size = N, replace = TRUE)
  38.   )
  39.    
  40. m1=lm(formula = LAY ~ LA1+LA2+LA3+LA4+LA5+LA6+LA7+LA8, data = df)
  41. m11=step(m1,direction="both")
  42.  
  43. m2=lm(formula = UFY ~  UF1+UF2+UF3+UF4+UF5+UF6,data = df)
  44. m22=step(m2,direction="both")
  45.  
  46. m3=lm(formula = EKY ~  EK1+EK2+EK3+EK4+EK5+EK6+EK7+EK8+EK9+EK10+EK11+EK12, data = df)
  47. m33=step(m3,direction="both")
  48.  
  49. m8=lm(formula = Z1 ~ LAY+UFY+EKY, data = df)
  50. m88=step(m8,direction="both")
  51.  
  52. m9=lm(formula = Z2 ~ LAY+UFY+EKY, data = df)
  53. m99=step(m9,direction="both")
  54.  
  55. m10=lm(formula = Z3 ~ LAY+UFY+EKY, data = df)
  56. m100=step(m10,direction="both")
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top