• Like

Loading…

Flash Player 9 (or above) is needed to view presentations.
We have detected that you do not have it on your computer. To install it, go here.

Uploaded on

第1回 Japan.R 1-2 の資料。

第1回 Japan.R 1-2 の資料。

More in: Education
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
1,424
On Slideshare
0
From Embeds
0
Number of Embeds
1

Actions

Shares
Downloads
25
Comments
0
Likes
5

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n

Transcript

  • 1. Japan.R ― 1-2― id:sakaue, @sakaue
  • 2. Agenda1. R2.3.4.
  • 3. Agenda1. R2.3.4.
  • 4. • [Enter] • > 3+5 [Enter] • > 10-3 [Enter] • > 2*3 [Enter] • > 100/20 [Enter] • > (12 + 34 -56) * 78 / 90 [Enter]
  • 5. •• > 100^1/2• > 100^(1/2)
  • 6. R
  • 7. “I dont know !” by fmgbain http://www.flickr.com/photos/fmgbain/4382010455/
  • 8. sqrt()• > sqrt(2)• > sqrt(144)• > sqrt(104976)•[ ]2
  • 9. sqrt()• > sqrt(2)• > sqrt(144)• > sqrt(104976)•[ ]2 • 2 3 1 • > 2^(1/3)
  • 10. ( )•R• q() help(xxx)•
  • 11. R
  • 12. R
  • 13. “I dont know !” by fmgbain http://www.flickr.com/photos/fmgbain/4382010455/
  • 14. “hako”• > hako <- c(1,2,3,4,5)• > hako • c() concatenate •
  • 15. c() “<-” hako <- c(1,2,3,4,5)<-
  • 16. hako1 5 5
  • 17. •> sqrt(hako)• > log(hako)
  • 18. sqrt(1), sqrt(2) ... sqrt(5) log(1), log (2) ... log (5)
  • 19. • summary()• table()• sum()• length()
  • 20. • mean()• max(), min()• median()• sd()
  • 21. • R• • q(), help(), sqrt(), log(), c()•
  • 22. OK
  • 23. Agenda1. R2.3.4.
  • 24. Agenda1. R2.3.4.
  • 25. ...••• TOEIC
  • 26. ...A 180 75B 170 65C 165 60D 175 70E 190 80
  • 27. R
  • 28. 1 2 34 5 67 8 9
  • 29. 1 2 34 5 67 8 9
  • 30. 1 2 34 5 67 8 9
  • 31. 1 2 34 5 67 8 9
  • 32. 1 2 34 5 67 8 9
  • 33. 1 2 34 5 67 8 9
  • 34. 1 2 34 5 67 8 9
  • 35. matrix()
  • 36. matrix()•• matrix( , , )•
  • 37. A 180 75B 170 65C 165 60D 175 70E 190 80
  • 38. karada <- matrix(c(180, 170, 165,175, 190, 75, 65, 60, 70, 80), 5, 2)1. c()2. matrix() • 5 23. karada
  • 39. > karada
  • 40. matrix(1:9,nrow=3,ncol=3) 1 4 7 2 5 8 3 6 9
  • 41. matrix(1:9,nrow=3,ncol=3,byrow=TRUE) 1 2 3 4 5 6 7 8 9
  • 42. 1.2.
  • 43. demo <- matrix(1:30,nrow=5,ncol=6) http://gyazo.com/76c58d5d6c8426a44f160897cda99671.png
  • 44. 2 → demo[2,] 2 → demo[,2]http://gyazo.com/6726084afd9e1cc4b03df85fe6bc0f29.png
  • 45. 2 4 → demo[c(2,4),]2 4 → demo[, c(2,4)]
  • 46. http://gyazo.com/a116c0e2f1284ea7d38bf7024d92f1cc.png
  • 47. • !••
  • 48. Agenda1. R2.3.4.
  • 49. Agenda1. R2.3.4.
  • 50. • • •
  • 51. B 175 65B 177 70B 174 75A 179 70O 170 60
  • 52. • Excel WS••
  • 53. ...• data.frame() (p.240)• (p.243)• (p.243)
  • 54. ...
  • 55. “173.365 - Come on, feel the noise” by Jeff the Trojan http://www.flickr.com/photos/trojanguy/3046207115/
  • 56. Agenda1. R2.3.4.
  • 57. Agenda1. R2.3.4.
  • 58. ...• Excel / OOo•
  • 59. • ... • •
  • 60. • Windows → • “MyDocuments”• Mac OS →• Linux up to you...
  • 61. • • getwd() • > getwd() • setwd() • > setwd("/Users/sakaue/Desktop/")
  • 62. • read.csv() • CSV • CSV: Comma Separated Value
  • 63. 1. sample.csv • XLS/XLSX2. > demo2 <- read.csv(“japanr1_2_sample.csv”)3. > demo2 [Enter]
  • 64. !!• > table(demo2[,2]) •• > mean(demo2[,3]) •• > hist(demo2[,4]) •
  • 65. •• CSV read.csv()• or
  • 66. CSV Excel “y2.d175 | Lasershow! Relax!” by B Rosen http://www.flickr.com/photos/rosengrant/4751386872/