Si, Carlos, gracias. Pero desafortunadamente el link con el PDF no funciona :( --JIV Sent from my phone. Please excuse my brevity and misspelling. On Jul 24, 2013, at 4:51 PM, Carlos Ortega <cof@qualityexcellence.es> wrote: Hola, ¿Viste la sugerencia/ayuda en StackOverflow?: http://stackoverflow.com/questions/17408930/twitter-first-example Saludos, Carlos Ortega www.qualityexcellence.es El 24 de julio de 2013 23:29, Jorge I Velez <jorgeivanvelez@gmail.com>escribió:> Muchas gracias Marcelino. Desafortunadamente al ejecutar el ejemplo que > aparece en > > ?registerTwitterOAuth > > obtengo > > twitCred$handshake() > Error: Unauthorized > > registerTwitterOAuth(twitCred) > Error in registerTwitterOAuth(twitCred) : > oauth has not completed its handshake > > Alguna otra sugerencia? > > Muchas gracias! > Jorge.- > > > > 2013/7/25 Marcelino de la Cruz <marcelino.delacruz@upm.es> > > > Mira aquí: > > > > ?registerTwitterOAuth > > > > El 24/07/2013 20:57, Jorge I Velez escribió: > > > >> Buenas tardes a tod@s, > >> > >> Estoy incursionando en el analisis de tweets utilizando el paquete > twitteR > >> y siguiendo http://www.webmining.cl/2012/**07/text-mining-de-twitter-** > >> usando-r/< > http://www.webmining.cl/2012/07/text-mining-de-twitter-usando-r/> > >> > >> > >> Desafortunadamente cuando ejecuto > >> > >> # cargar librerias > >> library(twitteR) > >> library(tm) > >> library(wordcloud) > >> > >> # recolecta tweets de @camila_vallejo > >> tweets = userTimeline("camila_vallejo", 2000) > >> > >> obtengo > >> > >> Error in twInterfaceObj$doAPICall(cmd, params, method, ...) : > >> OAuth authentication is required with Twitter's API v1.1 > >> > >> He buscado por varias horas como resolver este problema y aun no > encuentro > >> una solucion satisfactoria. Alguna sugerencia? > >> > >> Agradezco por adelantado la ayuda. Al final se encuentra mi > >> sessionInfo(). > >> > >> Saludos, > >> Jorge.- > >> > >> sessionInfo() > >>> > >> R version 3.0.0 Patched (2013-04-08 r62531) > >> Platform: x86_64-apple-darwin10.8.0 (64-bit) > >> > >> locale: > >> [1] en_AU.UTF-8/en_AU.UTF-8/en_AU.**UTF-8/C/en_AU.UTF-8/en_AU.UTF-**8 > >> > >> attached base packages: > >> [1] stats graphics grDevices utils datasets methods base > >> > >> other attached packages: > >> [1] wordcloud_2.4 RColorBrewer_1.0-5 Rcpp_0.10.4 > tm_0.5-9.1 > >> > >> [5] twitteR_1.1.7 rjson_0.2.12 ROAuth_0.9.3 > >> digest_0.6.3 > >> > >> [9] RCurl_1.95-4.1 bitops_1.0-5 > >> > >> loaded via a namespace (and not attached): > >> [1] parallel_3.0.0 slam_0.1-28 > >> > >> [[alternative HTML version deleted]] > >> > >> ______________________________**_________________ > >> R-help-es mailing list > >> R-help-es@r-project.org > >> https://stat.ethz.ch/mailman/**listinfo/r-help-es< > https://stat.ethz.ch/mailman/listinfo/r-help-es> > >> > >> > > > > [[alternative HTML version deleted]] > > > _______________________________________________ > R-help-es mailing list > R-help-es@r-project.org > https://stat.ethz.ch/mailman/listinfo/r-help-es > >-- Saludos, Carlos Ortega www.qualityexcellence.es [[alternative HTML version deleted]]
A ver si os sirve.
Desde que cambiaron la api a la v 1.1 la identificación a través de la api
es obligatoria para poder acceder a información.
El proceso que yo sigo es el siguiente:
#Se definen los datos de la app registrada en twitter dev
tw <- OAuthFactory$new(consumerKey="aquí consumerkey",
consumerSecret="aqui consumer secret",
requestURL="https://api.twitter.com/oauth/request_token
",
accessURL="https://api.twitter.com/oauth/access_token",
authURL="https://api.twitter.com/oauth/authorize")
#se genera un acceso de la app a la api. Aquí es engorroso porque se ha de
copiar la url generada en un navegador y volver a pegar en R el código de
acceso
tw$handshake()
#Se guarda para poderlo utilizar cuando se quiera y no tener que repetir la
operación anterior
save(tw, file="./data/credentials.RData")
#Una vez guardado se guarda y se registra
load("./data/credentials.RData")
registerTwitterOAuth(tw)
A partir de aquí en principio ya puedes utilizar twitteR sin problemas.
**
*Carlos Guadián Orta*
Mi Twitter es @carlosguadian <http://twitter.com/carlosguadian>
Mi blog es K-Government <http://www.k-government.com>
Mi perfil profesional en LinkedIn
<http://es.linkedin.com/in/carlosguadian>
Trabajo en Autoritas Consulting <http://www.autoritas.es>
Coordino #oGov <http://www.ogov.eu>
Escribo en Sesión de
Control<http://sesiondecontrol.com/author/carlosguadian/>
El 24 de julio de 2013 23:56, Jorge I Velez
<jorgeivanvelez@gmail.com>escribió:
> Si, Carlos, gracias. Pero desafortunadamente el link con el PDF no funciona
> :( --JIV
>
> Sent from my phone. Please excuse my brevity and misspelling.
>
> On Jul 24, 2013, at 4:51 PM, Carlos Ortega <cof@qualityexcellence.es>
> wrote:
>
> Hola,
>
> ¿Viste la sugerencia/ayuda en StackOverflow?:
>
> http://stackoverflow.com/questions/17408930/twitter-first-example
>
> Saludos,
> Carlos Ortega
> www.qualityexcellence.es
>
>
> El 24 de julio de 2013 23:29, Jorge I Velez <jorgeivanvelez@gmail.com
> >escribió:
>
> > Muchas gracias Marcelino. Desafortunadamente al ejecutar el ejemplo
que
> > aparece en
> >
> > ?registerTwitterOAuth
> >
> > obtengo
> >
> > twitCred$handshake()
> > Error: Unauthorized
> >
> > registerTwitterOAuth(twitCred)
> > Error in registerTwitterOAuth(twitCred) :
> > oauth has not completed its handshake
> >
> > Alguna otra sugerencia?
> >
> > Muchas gracias!
> > Jorge.-
> >
> >
> >
> > 2013/7/25 Marcelino de la Cruz <marcelino.delacruz@upm.es>
> >
> > > Mira aquí:
> > >
> > > ?registerTwitterOAuth
> > >
> > > El 24/07/2013 20:57, Jorge I Velez escribió:
> > >
> > >> Buenas tardes a tod@s,
> > >>
> > >> Estoy incursionando en el analisis de tweets utilizando el
paquete
> > twitteR
> > >> y siguiendo
> http://www.webmining.cl/2012/**07/text-mining-de-twitter-**
> > >> usando-r/<
> > http://www.webmining.cl/2012/07/text-mining-de-twitter-usando-r/>
> > >>
> > >>
> > >> Desafortunadamente cuando ejecuto
> > >>
> > >> # cargar librerias
> > >> library(twitteR)
> > >> library(tm)
> > >> library(wordcloud)
> > >>
> > >> # recolecta tweets de @camila_vallejo
> > >> tweets = userTimeline("camila_vallejo", 2000)
> > >>
> > >> obtengo
> > >>
> > >> Error in twInterfaceObj$doAPICall(cmd, params, method, ...) :
> > >> OAuth authentication is required with Twitter's API
v1.1
> > >>
> > >> He buscado por varias horas como resolver este problema y aun
no
> > encuentro
> > >> una solucion satisfactoria. Alguna sugerencia?
> > >>
> > >> Agradezco por adelantado la ayuda. Al final se encuentra mi
> > >> sessionInfo().
> > >>
> > >> Saludos,
> > >> Jorge.-
> > >>
> > >> sessionInfo()
> > >>>
> > >> R version 3.0.0 Patched (2013-04-08 r62531)
> > >> Platform: x86_64-apple-darwin10.8.0 (64-bit)
> > >>
> > >> locale:
> > >> [1]
en_AU.UTF-8/en_AU.UTF-8/en_AU.**UTF-8/C/en_AU.UTF-8/en_AU.UTF-**8
> > >>
> > >> attached base packages:
> > >> [1] stats graphics grDevices utils datasets methods
base
> > >>
> > >> other attached packages:
> > >> [1] wordcloud_2.4 RColorBrewer_1.0-5 Rcpp_0.10.4
> > tm_0.5-9.1
> > >>
> > >> [5] twitteR_1.1.7 rjson_0.2.12 ROAuth_0.9.3
> > >> digest_0.6.3
> > >>
> > >> [9] RCurl_1.95-4.1 bitops_1.0-5
> > >>
> > >> loaded via a namespace (and not attached):
> > >> [1] parallel_3.0.0 slam_0.1-28
> > >>
> > >> [[alternative HTML version deleted]]
> > >>
> > >> ______________________________**_________________
> > >> R-help-es mailing list
> > >> R-help-es@r-project.org
> > >> https://stat.ethz.ch/mailman/**listinfo/r-help-es<
> > https://stat.ethz.ch/mailman/listinfo/r-help-es>
> > >>
> > >>
> > >
> >
> > [[alternative HTML version deleted]]
> >
> >
> > _______________________________________________
> > R-help-es mailing list
> > R-help-es@r-project.org
> > https://stat.ethz.ch/mailman/listinfo/r-help-es
> >
> >
>
>
> --
> Saludos,
> Carlos Ortega
> www.qualityexcellence.es
>
> [[alternative HTML version deleted]]
>
>
> _______________________________________________
> R-help-es mailing list
> R-help-es@r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-help-es
>
>
[[alternative HTML version deleted]]
Muchas gracias Carlos por tu ayuda. Funciona muy bien! --JIV 2013/7/25 Carlos Guadián Orta <carlosguadian@gmail.com>> A ver si os sirve. > > Desde que cambiaron la api a la v 1.1 la identificación a través de la api > es obligatoria para poder acceder a información. > > El proceso que yo sigo es el siguiente: > > #Se definen los datos de la app registrada en twitter dev > > tw <- OAuthFactory$new(consumerKey="aquí consumerkey", > consumerSecret="aqui consumer secret", > requestURL=" > https://api.twitter.com/oauth/request_token", > accessURL="https://api.twitter.com/oauth/access_token > ", > authURL="https://api.twitter.com/oauth/authorize") > > #se genera un acceso de la app a la api. Aquí es engorroso porque se ha de > copiar la url generada en un navegador y volver a pegar en R el código de > acceso > tw$handshake() > > #Se guarda para poderlo utilizar cuando se quiera y no tener que repetir > la operación anterior > save(tw, file="./data/credentials.RData") > > #Una vez guardado se guarda y se registra > load("./data/credentials.RData") > registerTwitterOAuth(tw) > > A partir de aquí en principio ya puedes utilizar twitteR sin problemas. > > > > > > ** > *Carlos Guadián Orta* > Mi Twitter es @carlosguadian <http://twitter.com/carlosguadian> > Mi blog es K-Government <http://www.k-government.com> > Mi perfil profesional en LinkedIn<http://es.linkedin.com/in/carlosguadian> > Trabajo en Autoritas Consulting <http://www.autoritas.es> > Coordino #oGov <http://www.ogov.eu> > Escribo en Sesión de Control<http://sesiondecontrol.com/author/carlosguadian/> > > > El 24 de julio de 2013 23:56, Jorge I Velez <jorgeivanvelez@gmail.com>escribió: > > Si, Carlos, gracias. Pero desafortunadamente el link con el PDF no funciona >> :( --JIV >> >> Sent from my phone. Please excuse my brevity and misspelling. >> >> On Jul 24, 2013, at 4:51 PM, Carlos Ortega <cof@qualityexcellence.es> >> wrote: >> >> Hola, >> >> ¿Viste la sugerencia/ayuda en StackOverflow?: >> >> http://stackoverflow.com/questions/17408930/twitter-first-example >> >> Saludos, >> Carlos Ortega >> www.qualityexcellence.es >> >> >> El 24 de julio de 2013 23:29, Jorge I Velez <jorgeivanvelez@gmail.com >> >escribió: >> >> > Muchas gracias Marcelino. Desafortunadamente al ejecutar el ejemplo que >> > aparece en >> > >> > ?registerTwitterOAuth >> > >> > obtengo >> > >> > twitCred$handshake() >> > Error: Unauthorized >> > >> > registerTwitterOAuth(twitCred) >> > Error in registerTwitterOAuth(twitCred) : >> > oauth has not completed its handshake >> > >> > Alguna otra sugerencia? >> > >> > Muchas gracias! >> > Jorge.- >> > >> > >> > >> > 2013/7/25 Marcelino de la Cruz <marcelino.delacruz@upm.es> >> > >> > > Mira aquí: >> > > >> > > ?registerTwitterOAuth >> > > >> > > El 24/07/2013 20:57, Jorge I Velez escribió: >> > > >> > >> Buenas tardes a tod@s, >> > >> >> > >> Estoy incursionando en el analisis de tweets utilizando el paquete >> > twitteR >> > >> y siguiendo >> http://www.webmining.cl/2012/**07/text-mining-de-twitter-** >> > >> usando-r/< >> > http://www.webmining.cl/2012/07/text-mining-de-twitter-usando-r/> >> > >> >> > >> >> > >> Desafortunadamente cuando ejecuto >> > >> >> > >> # cargar librerias >> > >> library(twitteR) >> > >> library(tm) >> > >> library(wordcloud) >> > >> >> > >> # recolecta tweets de @camila_vallejo >> > >> tweets = userTimeline("camila_vallejo", 2000) >> > >> >> > >> obtengo >> > >> >> > >> Error in twInterfaceObj$doAPICall(cmd, params, method, ...) : >> > >> OAuth authentication is required with Twitter's API v1.1 >> > >> >> > >> He buscado por varias horas como resolver este problema y aun no >> > encuentro >> > >> una solucion satisfactoria. Alguna sugerencia? >> > >> >> > >> Agradezco por adelantado la ayuda. Al final se encuentra mi >> > >> sessionInfo(). >> > >> >> > >> Saludos, >> > >> Jorge.- >> > >> >> > >> sessionInfo() >> > >>> >> > >> R version 3.0.0 Patched (2013-04-08 r62531) >> > >> Platform: x86_64-apple-darwin10.8.0 (64-bit) >> > >> >> > >> locale: >> > >> [1] en_AU.UTF-8/en_AU.UTF-8/en_AU.**UTF-8/C/en_AU.UTF-8/en_AU.UTF-**8 >> > >> >> > >> attached base packages: >> > >> [1] stats graphics grDevices utils datasets methods base >> > >> >> > >> other attached packages: >> > >> [1] wordcloud_2.4 RColorBrewer_1.0-5 Rcpp_0.10.4 >> > tm_0.5-9.1 >> > >> >> > >> [5] twitteR_1.1.7 rjson_0.2.12 ROAuth_0.9.3 >> > >> digest_0.6.3 >> > >> >> > >> [9] RCurl_1.95-4.1 bitops_1.0-5 >> > >> >> > >> loaded via a namespace (and not attached): >> > >> [1] parallel_3.0.0 slam_0.1-28 >> > >> >> > >> [[alternative HTML version deleted]] >> > >> >> > >> ______________________________**_________________ >> > >> R-help-es mailing list >> > >> R-help-es@r-project.org >> > >> https://stat.ethz.ch/mailman/**listinfo/r-help-es< >> > https://stat.ethz.ch/mailman/listinfo/r-help-es> >> > >> >> > >> >> > > >> > >> > [[alternative HTML version deleted]] >> > >> > >> > _______________________________________________ >> > R-help-es mailing list >> > R-help-es@r-project.org >> > https://stat.ethz.ch/mailman/listinfo/r-help-es >> > >> > >> >> >> -- >> Saludos, >> Carlos Ortega >> www.qualityexcellence.es >> >> [[alternative HTML version deleted]] >> >> >> _______________________________________________ >> R-help-es mailing list >> R-help-es@r-project.org >> https://stat.ethz.ch/mailman/listinfo/r-help-es >> >> >[[alternative HTML version deleted]]