Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/leeper/webuse
Import Stata 'webuse' Datasets
https://github.com/leeper/webuse
cran data-import dataset r stata stata-datasets
Last synced: 4 days ago
JSON representation
Import Stata 'webuse' Datasets
- Host: GitHub
- URL: https://github.com/leeper/webuse
- Owner: leeper
- License: other
- Created: 2015-06-17T12:17:58.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2018-09-30T22:49:12.000Z (over 6 years ago)
- Last Synced: 2025-02-02T20:12:24.873Z (18 days ago)
- Topics: cran, data-import, dataset, r, stata, stata-datasets
- Language: R
- Homepage: https://cloud.r-project.org/package=webuse
- Size: 37.1 KB
- Stars: 6
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.Rmd
- License: LICENSE
Awesome Lists containing this project
README
# Import Stata 'webuse' Datasets
This package provides a Stata-style `webuse()` function for importing named datasets from Stata's online collection.
## Package Installation
This package can be installed from R using `install.packages("webuse")` or from GitHub using **remotes**:
```R
if(!require("remotes")){
install.packages("remotes")
}
remotes::install_github("leeper/webuse")
```[](https://travis-ci.org/leeper/webuse)
[](http://cran.r-project.org/package=webuse)
## Code Examples
```{r, echo=FALSE, results='hide'}
options(width = 100)
```Functionality is simple. Load **webuse** and then access any online Stata dataset using the `webuse()` function. This will assign the named dataset to the `.GlobalEnv` (or another environment, if specified):
```{r}
library("webuse")
webuse("auto")
head(auto)webuse("uslifeexp")
head(uslifeexp)
```The `webuselist` object contains a list of "core" Stata datasets:
```{r}
str(webuselist)
```