Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Devtools Document throwing Error

Tags:

r

devtools

I am putting together an R data package, and I have been documenting the datasets without issue until now. The following is included in a file called charges_ay.R located in the R folder in package repo.

#' Student Charges for Academic Year programs.
#'
#' For more information, download a data dictionary from the IPEDS website.
#' 
#' Survey years 2002 - 2014.
#'
#' @source http://nces.ed.gov/ipeds/datacenter/DataFiles.aspx
#' @format Data frame with columns
"charges_ay"

When I attempt to run devtools::document from the base of the package (as I have for the other files), I get the following error:

> devtools::document()
Updating ripeds documentation
Loading ripeds
Error: 'charges_ay' is not an exported object from 'namespace:ripeds'

Given that everything has worked fine until now, I am bit confused as the process and file documentation are all the same.

Any help will be greatly appreciated!

like image 439
Btibert3 Avatar asked Mar 24 '16 14:03

Btibert3


1 Answers

When I ran in to this in my own package, it seemed to be a workflow issue. Try either running use_data(charges_ay) prior to document(), or adding use_data(charges_ay) at the end of your data-generating file.

like image 110
Von Avatar answered Nov 08 '22 15:11

Von