https://github.com/tylerlittlefield/rstats-tweets
Collects tweets with the keyword 'rstats'
https://github.com/tylerlittlefield/rstats-tweets
cron data-collection rstats rtweet
Last synced: 10 months ago
JSON representation
Collects tweets with the keyword 'rstats'
- Host: GitHub
- URL: https://github.com/tylerlittlefield/rstats-tweets
- Owner: tylerlittlefield
- Created: 2020-02-10T03:34:31.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2021-01-07T02:16:31.000Z (over 5 years ago)
- Last Synced: 2025-06-12T06:51:36.331Z (12 months ago)
- Topics: cron, data-collection, rstats, rtweet
- Language: R
- Homepage:
- Size: 14.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.Rmd
Awesome Lists containing this project
README
---
output: github_document
---
```{r, options, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>"
)
```
# rstats-tweets
This repository collects twitter data and stores it to my own personal s3 bucket. More specifically, it...
* Uses `rtweet` to search for tweets with _rstats_ in the text.
* Compares new tweets to tweets that I have already collected by filtering out status IDs that already exist.
* Saves the dataset to a personal s3 bucket.
* Does this daily using a cron job from `cronR`.
I have no real use case for this at the moment. I am more or less just interested in setting up a job to collect data. I think of it as a kind of template that I may come back to if there is any twitter data I'd like to routinely collect.
```{r, example, echo=FALSE, warning=FALSE, message=FALSE}
library(dplyr)
library(aws.s3)
df <- s3readRDS(
object = "rstats_tweets.rds",
bucket = "tylerlittlefield"
)
df %>%
distinct(
created_at,
text
)
```