https://github.com/news-r/stocknews
📈 Access Stock News API from R
https://github.com/news-r/stocknews
api media news r rstats
Last synced: 3 months ago
JSON representation
📈 Access Stock News API from R
- Host: GitHub
- URL: https://github.com/news-r/stocknews
- Owner: news-r
- License: other
- Created: 2019-06-10T11:35:19.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-06-12T11:19:37.000Z (over 5 years ago)
- Last Synced: 2024-08-13T07:13:57.299Z (6 months ago)
- Topics: api, media, news, r, rstats
- Language: R
- Homepage:
- Size: 7.81 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.Rmd
- License: LICENSE
Awesome Lists containing this project
- jimsghstars - news-r/stocknews - 📈 Access Stock News API from R (R)
README
---
output: github_document
---```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```[](https://travis-ci.org/news-r/stocknews)
[](https://ci.appveyor.com/project/news-r/stocknews)# stocknews
Access [Stock News API](https://stocknewsapi.com) from R.
## Installation
``` r
# install.packages("remotes")
remotes::install_github("news-r/stocknews")
```## Setup
Create a free account at [stocknewsapi.com](https://stocknewsapi.com) to create an API key.
```r
stocknews_key("xxXXxxXx")
```Note that you can specify the `STOCKNEWS_API_KEY` key as an environment variable in your `.Renviron` for convenience.
## Example
```{r}
library(stocknews)tickers <- sn_tickers(c("AMZN", "GOOG"))
(sections <- sn_category("general"))
```