SlideShare uma empresa Scribd logo
1 de 49
Baixar para ler offline
twitteR   R
          Japan.R #2 (2011/11/26)
                        @a_bicky
• Takeshi Arabiki
    ‣

    ‣ Twitter &          : @a_bicky & id:a_bicky

•
                                R

•
                  http://d.hatena.ne.jp/a_bicky/
R
           Osaka.R #4                               Tokyo.R #16                               Tsukuba.R #9




http://www.slideshare.net/abicky/twitterr   http://www.slideshare.net/abicky/r-9034336 http://www.slideshare.net/abicky/r-10128090
R
           Osaka.R #4                               Tokyo.R #16                               Tsukuba.R #9




http://www.slideshare.net/abicky/twitterr   http://www.slideshare.net/abicky/r-9034336 http://www.slideshare.net/abicky/r-10128090



                        http://www.slideshare.net/abicky/rtwitter
LT
twitteR
•                                 RJSONIO
•
•             ID   status ID
• fav               favorited   TRUE
• truncated   TRUE
• DM
• status
  character   factor
twitteR
•                                 RJSONIO
•
•             ID   status ID
• fav               favorited   TRUE
• truncated   TRUE
• DM
• status
  character   factor
OAuth   ”   ”   twitteR   -
OAuth   ”   ”   twitteR   -
OAuth   ”   ”   twitteR   -
OAuth   ”   ”   twitteR   -




                              twittoru
OAuth   ”   ”   twitteR   -
OAuth   ”   ”   twitteR   -
OAuth   ”   ”   twitteR        -




                          twittoru
OAuth   ”   ”   twitteR        -




                          twittoru
OAuth   ”   ”   twitteR        -




R
                          twittoru
OAuth   ”   ”   twitteR        -




                yokkuns
                          twittoru
for Unix users
for Unix users
Windows
$ sudo R -e 'install.packages("twitteR")'
$ sudo R -e 'install.packages("ROAuth")'
RJSONIO

$ sudo R CMD remove RJSONIO # 0.3
$ wget http://cran.r-project.org/src/contrib/Archive/RJSONIO/
RJSONIO_0.3-1.tar.gz
$ sudo R CMD install RJSONIO_0.3-1.tar.gz
twitteR   ROAuth

$ wget https://raw.github.com/gist/1378878 -O ROAuch.patch
$ wget http://cran.r-project.org/src/contrib/
ROAuth_0.9.0.tar.gz
$ tar xvfz ROAuth_0.9.0.tar.gz
$ patch -c -p1 -d ROAuth < ROAuth.patch
$ sudo R CMD remove ROAuth
$ sudo R CMD install ROAuth
$ wget https://raw.github.com/gist/1378880 -O twitteR.patch
$ wget http://cran.r-project.org/src/contrib/
twitteR_0.99.14.tar.gz
$ tar xvfz twitteR_0.99.14.tar.gz
$ patch -c -p1 -d twitteR < twitteR.patch
$ sudo R CMD remove twitteR
$ sudo R CMD install twitteR
https://dev.twitter.com/
https://dev.twitter.com/
https://dev.twitter.com/
https://dev.twitter.com/
←


←


←   URL
←

    Developer Rules Of The Road
            ←
   “Yes, I agree”
            ←                       URL
“Create your Twitter application”
“twitter”
← Consumer key
← Consumer secret
“Read, Write and Access direct messages”
        “Update this Twitter application’s settings”
access token
access token
access token
access token


                                   ← Access token
                                   ← Access token secret


Read, write, and direct messages
twitteR
init_twitteR.R
 library(twitteR)
 library(ROAuth)
 #
 Sys.setlocale("LC_TIME", "en_US.utf-8")

 #
 twit.oauth <- OAuthFactory$new(
          handshakeComplete = TRUE,
          signMethod = "HMAC",
          consumerKey = "vFIR1AYuMJN8X997BjplRw",
          consumerSecret = "p9ZtKxJONDdBO1rIYNiBSmXLJj3W0cKdizremBPb6T4",
          oauthKey = "103027920-8tmAeUQHLxIbDGmjrpJURCKQEDpxu7uHQrGLqphW",
          oauthSecret = "0ixZIMBDRQElQ9P2IrTNIeIvqR7zJzSp6ShNolYcbSE")
 # OAuth
 registerTwitterOAuth(twit.oauth)
twitteR
init_twitteR.R
 library(twitteR)
 library(ROAuth)
 #
 Sys.setlocale("LC_TIME", "en_US.utf-8")

 #
 twit.oauth <- OAuthFactory$new(
          handshakeComplete = TRUE,
          signMethod = "HMAC",
          consumerKey = "vFIR1AYuMJN8X997BjplRw",
          consumerSecret = "p9ZtKxJONDdBO1rIYNiBSmXLJj3W0cKdizremBPb6T4",
          oauthKey = "103027920-8tmAeUQHLxIbDGmjrpJURCKQEDpxu7uHQrGLqphW",
          oauthSecret = "0ixZIMBDRQElQ9P2IrTNIeIvqR7zJzSp6ShNolYcbSE")
 # OAuth
 registerTwitterOAuth(twit.oauth)




                       ※
> source("init_twitteR.R")
> tweet("Japan.R         #japanr")
DM

> taskStatus({
+     x <- sample(as.numeric(1:100), 100000000, replace =
TRUE)
+     ret <- sum(x)
+ }, "a_bicky", sprintf("           %s", ret))
[1] 5049839571
DM

> taskStatus({
+     x <- sample(as.numeric(1:100), 100000000, replace =
TRUE)
+     ret <- sum(x)
+ }, "a_bicky", sprintf("           %s", ret))
[1] 5049839571
R

Mais conteúdo relacionado

Mais procurados

The groovy puzzlers (as Presented at JavaOne 2014)
The groovy puzzlers (as Presented at JavaOne 2014)The groovy puzzlers (as Presented at JavaOne 2014)
The groovy puzzlers (as Presented at JavaOne 2014)
GroovyPuzzlers
 
mobl - model-driven engineering lecture
mobl - model-driven engineering lecturemobl - model-driven engineering lecture
mobl - model-driven engineering lecture
zefhemel
 
MongoUK - PHP Development
MongoUK - PHP DevelopmentMongoUK - PHP Development
MongoUK - PHP Development
Boxed Ice
 
第二讲 预备-Python基礎
第二讲 预备-Python基礎第二讲 预备-Python基礎
第二讲 预备-Python基礎
anzhong70
 

Mais procurados (20)

Functional Pe(a)rls - the Purely Functional Datastructures edition
Functional Pe(a)rls - the Purely Functional Datastructures editionFunctional Pe(a)rls - the Purely Functional Datastructures edition
Functional Pe(a)rls - the Purely Functional Datastructures edition
 
Exploring slides
Exploring slidesExploring slides
Exploring slides
 
program on string in java Lab file 2 (3-year)
program on string in java Lab file 2 (3-year)program on string in java Lab file 2 (3-year)
program on string in java Lab file 2 (3-year)
 
RxSwift 시작하기
RxSwift 시작하기RxSwift 시작하기
RxSwift 시작하기
 
Functional Pe(a)rls version 2
Functional Pe(a)rls version 2Functional Pe(a)rls version 2
Functional Pe(a)rls version 2
 
Is Haskell an acceptable Perl?
Is Haskell an acceptable Perl?Is Haskell an acceptable Perl?
Is Haskell an acceptable Perl?
 
dplyr and torrents from cpasbien
dplyr and torrents from cpasbiendplyr and torrents from cpasbien
dplyr and torrents from cpasbien
 
The groovy puzzlers (as Presented at JavaOne 2014)
The groovy puzzlers (as Presented at JavaOne 2014)The groovy puzzlers (as Presented at JavaOne 2014)
The groovy puzzlers (as Presented at JavaOne 2014)
 
mobl - model-driven engineering lecture
mobl - model-driven engineering lecturemobl - model-driven engineering lecture
mobl - model-driven engineering lecture
 
MongoDB Europe 2016 - Enabling the Internet of Things at Proximus - Belgium's...
MongoDB Europe 2016 - Enabling the Internet of Things at Proximus - Belgium's...MongoDB Europe 2016 - Enabling the Internet of Things at Proximus - Belgium's...
MongoDB Europe 2016 - Enabling the Internet of Things at Proximus - Belgium's...
 
M12 random forest-part01
M12 random forest-part01M12 random forest-part01
M12 random forest-part01
 
M09-Cross validating-naive-bayes
M09-Cross validating-naive-bayesM09-Cross validating-naive-bayes
M09-Cross validating-naive-bayes
 
Spark DataFrames for Data Munging
Spark DataFrames for Data MungingSpark DataFrames for Data Munging
Spark DataFrames for Data Munging
 
Malcon2017
Malcon2017Malcon2017
Malcon2017
 
The Ring programming language version 1.5.2 book - Part 45 of 181
The Ring programming language version 1.5.2 book - Part 45 of 181The Ring programming language version 1.5.2 book - Part 45 of 181
The Ring programming language version 1.5.2 book - Part 45 of 181
 
Lập trình Python cơ bản
Lập trình Python cơ bảnLập trình Python cơ bản
Lập trình Python cơ bản
 
(gentle (introduction Clojure))
(gentle (introduction Clojure))(gentle (introduction Clojure))
(gentle (introduction Clojure))
 
The Browser Environment - A Systems Programmer's Perspective
The Browser Environment - A Systems Programmer's PerspectiveThe Browser Environment - A Systems Programmer's Perspective
The Browser Environment - A Systems Programmer's Perspective
 
MongoUK - PHP Development
MongoUK - PHP DevelopmentMongoUK - PHP Development
MongoUK - PHP Development
 
第二讲 预备-Python基礎
第二讲 预备-Python基礎第二讲 预备-Python基礎
第二讲 预备-Python基礎
 

Semelhante a twitteRで快適Rライフ!

Semelhante a twitteRで快適Rライフ! (20)

Ruby Robots
Ruby RobotsRuby Robots
Ruby Robots
 
Api
ApiApi
Api
 
Django REST Framework における API 実装プラクティス | PyCon JP 2018
Django REST Framework における API 実装プラクティス | PyCon JP 2018Django REST Framework における API 実装プラクティス | PyCon JP 2018
Django REST Framework における API 実装プラクティス | PyCon JP 2018
 
Onsg10 Intro Termtter
Onsg10 Intro TermtterOnsg10 Intro Termtter
Onsg10 Intro Termtter
 
Mining the social web ch1
Mining the social web ch1Mining the social web ch1
Mining the social web ch1
 
Raphaël and You
Raphaël and YouRaphaël and You
Raphaël and You
 
GDG DevFest Kyoto 2014 これからのGoの話をしよう
GDG DevFest Kyoto 2014 これからのGoの話をしようGDG DevFest Kyoto 2014 これからのGoの話をしよう
GDG DevFest Kyoto 2014 これからのGoの話をしよう
 
Beyond PHP - it's not (just) about the code
Beyond PHP - it's not (just) about the codeBeyond PHP - it's not (just) about the code
Beyond PHP - it's not (just) about the code
 
AWS DEV DAY SEOUL 2017 Buliding Serverless Web App - 직방 Image Converter
AWS DEV DAY SEOUL 2017 Buliding Serverless Web App - 직방 Image ConverterAWS DEV DAY SEOUL 2017 Buliding Serverless Web App - 직방 Image Converter
AWS DEV DAY SEOUL 2017 Buliding Serverless Web App - 직방 Image Converter
 
Practical Introduction to Web scraping using R
Practical Introduction to Web scraping using RPractical Introduction to Web scraping using R
Practical Introduction to Web scraping using R
 
Tribal Leadership with Dave Logan
Tribal Leadership with Dave LoganTribal Leadership with Dave Logan
Tribal Leadership with Dave Logan
 
Data Mangling with mongoDB the Right Way [PyData London] 2016]
Data Mangling with mongoDB the Right Way [PyData London] 2016]Data Mangling with mongoDB the Right Way [PyData London] 2016]
Data Mangling with mongoDB the Right Way [PyData London] 2016]
 
I Don't Care About Security (And Neither Should You)
I Don't Care About Security (And Neither Should You)I Don't Care About Security (And Neither Should You)
I Don't Care About Security (And Neither Should You)
 
Grokking Grok: Monitorama PDX 2015
Grokking Grok: Monitorama PDX 2015Grokking Grok: Monitorama PDX 2015
Grokking Grok: Monitorama PDX 2015
 
Доклад Антона Поварова "Go in Badoo" с Golang Meetup
Доклад Антона Поварова "Go in Badoo" с Golang MeetupДоклад Антона Поварова "Go in Badoo" с Golang Meetup
Доклад Антона Поварова "Go in Badoo" с Golang Meetup
 
☣ ppencode ♨
☣ ppencode ♨☣ ppencode ♨
☣ ppencode ♨
 
Shrimp: A Rather Practical Example Of Application Development With RESTinio a...
Shrimp: A Rather Practical Example Of Application Development With RESTinio a...Shrimp: A Rather Practical Example Of Application Development With RESTinio a...
Shrimp: A Rather Practical Example Of Application Development With RESTinio a...
 
UAA for Kubernetes
UAA for KubernetesUAA for Kubernetes
UAA for Kubernetes
 
서버리스(Serverless) 웹 애플리케이션 구축하기
서버리스(Serverless) 웹 애플리케이션 구축하기서버리스(Serverless) 웹 애플리케이션 구축하기
서버리스(Serverless) 웹 애플리케이션 구축하기
 
Mobile Social Apps and Ads JP version
Mobile Social Apps and Ads JP versionMobile Social Apps and Ads JP version
Mobile Social Apps and Ads JP version
 

Mais de Takeshi Arabiki

Introduction to Japanese Morphological Analysis
Introduction to Japanese Morphological AnalysisIntroduction to Japanese Morphological Analysis
Introduction to Japanese Morphological Analysis
Takeshi Arabiki
 
Rのデータ構造とメモリ管理
Rのデータ構造とメモリ管理Rのデータ構造とメモリ管理
Rのデータ構造とメモリ管理
Takeshi Arabiki
 
Introduction to Favmemo for Immature Engineers
Introduction to Favmemo for Immature EngineersIntroduction to Favmemo for Immature Engineers
Introduction to Favmemo for Immature Engineers
Takeshi Arabiki
 

Mais de Takeshi Arabiki (16)

開発の心得
開発の心得開発の心得
開発の心得
 
クックパッド特売情報 における自然言語処理 〜固有表現抽出を利用した検索システム〜
クックパッド特売情報 における自然言語処理 〜固有表現抽出を利用した検索システム〜クックパッド特売情報 における自然言語処理 〜固有表現抽出を利用した検索システム〜
クックパッド特売情報 における自然言語処理 〜固有表現抽出を利用した検索システム〜
 
Introduction to Japanese Morphological Analysis
Introduction to Japanese Morphological AnalysisIntroduction to Japanese Morphological Analysis
Introduction to Japanese Morphological Analysis
 
R による文書分類入門
R による文書分類入門R による文書分類入門
R による文書分類入門
 
Rのデータ構造とメモリ管理
Rのデータ構造とメモリ管理Rのデータ構造とメモリ管理
Rのデータ構造とメモリ管理
 
HTML5 Canvas で学ぶアフィン変換
HTML5 Canvas で学ぶアフィン変換HTML5 Canvas で学ぶアフィン変換
HTML5 Canvas で学ぶアフィン変換
 
Introduction to Favmemo for Immature Engineers
Introduction to Favmemo for Immature EngineersIntroduction to Favmemo for Immature Engineers
Introduction to Favmemo for Immature Engineers
 
Rのスコープとフレームと環境と
Rのスコープとフレームと環境とRのスコープとフレームと環境と
Rのスコープとフレームと環境と
 
R版Getopt::Longを作ってみた
R版Getopt::Longを作ってみたR版Getopt::Longを作ってみた
R版Getopt::Longを作ってみた
 
Rデータフレーム自由自在
Rデータフレーム自由自在Rデータフレーム自由自在
Rデータフレーム自由自在
 
HMM, MEMM, CRF メモ
HMM, MEMM, CRF メモHMM, MEMM, CRF メモ
HMM, MEMM, CRF メモ
 
文字列カーネルによる辞書なしツイート分類 〜文字列カーネル入門〜
文字列カーネルによる辞書なしツイート分類 〜文字列カーネル入門〜文字列カーネルによる辞書なしツイート分類 〜文字列カーネル入門〜
文字列カーネルによる辞書なしツイート分類 〜文字列カーネル入門〜
 
Rデバッグあれこれ
RデバッグあれこれRデバッグあれこれ
Rデバッグあれこれ
 
はじめてのまっぷりでゅ〜す
はじめてのまっぷりでゅ〜すはじめてのまっぷりでゅ〜す
はじめてのまっぷりでゅ〜す
 
TwitterのデータをRであれこれ
TwitterのデータをRであれこれTwitterのデータをRであれこれ
TwitterのデータをRであれこれ
 
Twitterのデータを取得する準備
Twitterのデータを取得する準備Twitterのデータを取得する準備
Twitterのデータを取得する準備
 

Último

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 

Último (20)

08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 

twitteRで快適Rライフ!

  • 1. twitteR R Japan.R #2 (2011/11/26) @a_bicky
  • 2. • Takeshi Arabiki ‣ ‣ Twitter & : @a_bicky & id:a_bicky • R • http://d.hatena.ne.jp/a_bicky/
  • 3. R Osaka.R #4 Tokyo.R #16 Tsukuba.R #9 http://www.slideshare.net/abicky/twitterr http://www.slideshare.net/abicky/r-9034336 http://www.slideshare.net/abicky/r-10128090
  • 4. R Osaka.R #4 Tokyo.R #16 Tsukuba.R #9 http://www.slideshare.net/abicky/twitterr http://www.slideshare.net/abicky/r-9034336 http://www.slideshare.net/abicky/r-10128090 http://www.slideshare.net/abicky/rtwitter
  • 5. LT
  • 6. twitteR • RJSONIO • • ID status ID • fav favorited TRUE • truncated TRUE • DM • status character factor
  • 7. twitteR • RJSONIO • • ID status ID • fav favorited TRUE • truncated TRUE • DM • status character factor
  • 8. OAuth ” ” twitteR -
  • 9. OAuth ” ” twitteR -
  • 10. OAuth ” ” twitteR -
  • 11. OAuth ” ” twitteR - twittoru
  • 12. OAuth ” ” twitteR -
  • 13. OAuth ” ” twitteR -
  • 14. OAuth ” ” twitteR - twittoru
  • 15. OAuth ” ” twitteR - twittoru
  • 16. OAuth ” ” twitteR - R twittoru
  • 17. OAuth ” ” twitteR - yokkuns twittoru
  • 18.
  • 19.
  • 22. $ sudo R -e 'install.packages("twitteR")' $ sudo R -e 'install.packages("ROAuth")'
  • 23. RJSONIO $ sudo R CMD remove RJSONIO # 0.3 $ wget http://cran.r-project.org/src/contrib/Archive/RJSONIO/ RJSONIO_0.3-1.tar.gz $ sudo R CMD install RJSONIO_0.3-1.tar.gz
  • 24. twitteR ROAuth $ wget https://raw.github.com/gist/1378878 -O ROAuch.patch $ wget http://cran.r-project.org/src/contrib/ ROAuth_0.9.0.tar.gz $ tar xvfz ROAuth_0.9.0.tar.gz $ patch -c -p1 -d ROAuth < ROAuth.patch $ sudo R CMD remove ROAuth $ sudo R CMD install ROAuth $ wget https://raw.github.com/gist/1378880 -O twitteR.patch $ wget http://cran.r-project.org/src/contrib/ twitteR_0.99.14.tar.gz $ tar xvfz twitteR_0.99.14.tar.gz $ patch -c -p1 -d twitteR < twitteR.patch $ sudo R CMD remove twitteR $ sudo R CMD install twitteR
  • 29.
  • 30.
  • 31. ← ← ← URL
  • 32. Developer Rules Of The Road ← “Yes, I agree” ← URL “Create your Twitter application”
  • 33.
  • 35.
  • 36. ← Consumer key ← Consumer secret
  • 37.
  • 38. “Read, Write and Access direct messages” “Update this Twitter application’s settings”
  • 42. access token ← Access token ← Access token secret Read, write, and direct messages
  • 43. twitteR init_twitteR.R library(twitteR) library(ROAuth) # Sys.setlocale("LC_TIME", "en_US.utf-8") # twit.oauth <- OAuthFactory$new( handshakeComplete = TRUE, signMethod = "HMAC", consumerKey = "vFIR1AYuMJN8X997BjplRw", consumerSecret = "p9ZtKxJONDdBO1rIYNiBSmXLJj3W0cKdizremBPb6T4", oauthKey = "103027920-8tmAeUQHLxIbDGmjrpJURCKQEDpxu7uHQrGLqphW", oauthSecret = "0ixZIMBDRQElQ9P2IrTNIeIvqR7zJzSp6ShNolYcbSE") # OAuth registerTwitterOAuth(twit.oauth)
  • 44. twitteR init_twitteR.R library(twitteR) library(ROAuth) # Sys.setlocale("LC_TIME", "en_US.utf-8") # twit.oauth <- OAuthFactory$new( handshakeComplete = TRUE, signMethod = "HMAC", consumerKey = "vFIR1AYuMJN8X997BjplRw", consumerSecret = "p9ZtKxJONDdBO1rIYNiBSmXLJj3W0cKdizremBPb6T4", oauthKey = "103027920-8tmAeUQHLxIbDGmjrpJURCKQEDpxu7uHQrGLqphW", oauthSecret = "0ixZIMBDRQElQ9P2IrTNIeIvqR7zJzSp6ShNolYcbSE") # OAuth registerTwitterOAuth(twit.oauth) ※
  • 46.
  • 47. DM > taskStatus({ + x <- sample(as.numeric(1:100), 100000000, replace = TRUE) + ret <- sum(x) + }, "a_bicky", sprintf(" %s", ret)) [1] 5049839571
  • 48. DM > taskStatus({ + x <- sample(as.numeric(1:100), 100000000, replace = TRUE) + ret <- sum(x) + }, "a_bicky", sprintf(" %s", ret)) [1] 5049839571
  • 49. R