Skip to content
master
Go to file
Code

Latest commit

* add delimeter detection

* fix documentation

* update the documentation vs actual code

* cannot access data via `$`for some reason. but now it will only load files called out in the readme, resolving issue #20

* drop show_readme function - redundant to readme function

* bump version

* improve read speed, and add user ability to pass args to tt_read_data from tt_load

* resolve build check errors, make readme exported...

* try rolling back and specifying min version of rlang necessary

* move up rlang and dplyr version

* update min package versions for travis?

* update minimum package versions

* attempting to make pkgdown site for {tidytuesdayR}

* bump version to dev number

* add print method and add more tests

* update documentation for print method

* Add README.Rmd

* Make pkgdown work (#32)

* try to get pkgdown to use the readme

* Add pkgdown to suggests

* Update DESCRIPTION

bump version number

* remove README.Rmd

* Gdpr data (#45)

* Path replace fix (#43)

* update URL path corrections

* Improvement on file-finding abilities...

* first updates to api

* update github calls to add blob and authentication

* working on updating file downloading via github api

* updates to allow for setting ref repo in options

* add documentation

* updates to printing tt_available

* updates to tests & docs to pass devtools::check

* add auth to downloading sha within tt_download

* Looking to remove travis/appveyor dep

* update to reference full path and stringsAsFactors not being TRUE by default now.

* Add token to github_pat function

* add GITHUB_PAT as token

* add travis and appveyor back in

* hopefully this fixes appveyor

* remove travis and move code coverage to github actions (#49)

* update news, bump major version

* add github api limiting feature

* Cran release prep v1 (#52)

* prepping for CRAN release

* Add Cran Comments

* Increment version number

* Tidytemplates (#61)

* Create tidytemplate

* update documentation

* update for missing imports and partial arg match

* complete updates to tidytemplate

* wrap tests in tt_ref_test_that and add api check

* html encoding error (#62)

* unpdate to allow for general encoding

* Fix so only specific locale needed updating (CTYPE)

* Increment version number

* update news

* add CRAN comments

* spelling

* cran release

* update func to pass args to parsing funcs

* Increment version number

* Update github_api.R (#67)

malformed check against github api, for some reason worked everywhere but rstudio cloud? #65

* Documentation correction (#70)

* Update to make missing delim acceptable (#66)

* Update to make missing delim acceptable

* Update R-CMD-check.yaml

* Update R-CMD-check.yaml

undo updates 🙄

* Update tt_download.R

Correct documentation

* update docs

* fix order of link and code
51dfba6

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
R
 
 
 
 
man
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

readme.md

tidytuesdayR

Ellis Hughes

CRAN status R build status Coverage status Downloads from the RStudio CRAN mirror License: MIT

{tidytuesdayR} has the main goal to make it easy to participate in the weekly #TidyTuesday project. Currently this is done by assisting with the import of data posted on the R4DataScience Tidy Tuesday repository.

Installation

This package is available on CRAN via:

install.packages("tidytuesdayR")

To get the latest in-development features, install the development version from GitHub:

#install.packages("remotes")
remotes::install_github("thebioengineer/tidytuesdayR")

Usage

There are currently two methods to access the data from the respository.

Load the Data!

The simplest way is to use the ‘tt_load()’ function. This function has accepts two types of inputs to determine which data to grab. It can be a date as a string in the YYYY-MM-DD format like below.

library(tidytuesdayR)
tt_data <- tt_load("2019-01-15")

Or the function can accept the year as the first argument, and which week of the year as the second.

tt_data <- tt_load(2019, week=3) 

tt_load() naively downloads all the data that is available and stores them in the resulting tt_data object. To access the data, use the $ or [[ notation and the name of the dataset.

tt_data$agencies
tt_data[["agencies"]]

To view the readme, either print the tt_data object or use the readme() function. When you print the tt_data object, you also get the available datasets names printed in the console.

readme(tt_data)
print(tt_data)
## Available Datasets:
##  agencies 
##  launches 
##  

TidyTemplate

As part of the goal of making participating in #TidyTuesday easier, {tidytuesdayR} now also provides a template! To use it, just use the use_tidytemplate() function!

By default, the template will assume to be using the most recent TidyTuesday. However, you can pass a date object or character string in YYYY-MM-DD format defining a different date you want to use. If you don't recall the exact date, no worries, you can use the tt_available() function to figure out which date and get the date to use!

## this weeks TidyTuesday!
tidytuesdayR::use_tidytemplate()

## TidyTuesday from Week 42 of 2019
tidytuesdayR::use_tidytemplate(refdate = "2019-10-15")

Additionally, by default the template will create the new file in your working directory, using the "YYYY_MM_DD" format per good practices. However, if you are so inclined, you can rename it to whatever you wish.

tidytuesdayR::use_tidytemplate(name = "My Super Great TidyTuesday.Rmd")

Contributing

Please note that the ‘tidytuesdayR’ project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.

You can’t perform that action at this time.