debian/0000755000000000000000000000000012213071136007162 5ustar debian/patches/0000755000000000000000000000000012213067424010616 5ustar debian/patches/series0000644000000000000000000000001412164603504012026 0ustar rjson.patch debian/patches/rjson.patch0000644000000000000000000000464412213067424013002 0ustar Description: Use rjson package instead of RJSONIO WDI normally uses RJSONIO, which is faster than rjson. Unfortunately, RJSONIO is nonfree (it is affected by the infamous "good, not evil" clause, see #712159). Author: Sébastien Villemot Forwarded: not-needed Last-Update: 2013-09-08 --- This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ --- a/DESCRIPTION +++ b/DESCRIPTION @@ -12,7 +12,7 @@ URL: http://www.umich.edu/~varel , https://www.github.com/vincentarelbundock/WDI Date: 2013-08-20 -Depends: RJSONIO +Depends: rjson Collate: 'WDI.R' 'WDI-package.R' 'WDI_data.R' Packaged: 2013-08-20 20:36:04 UTC; hotsauce NeedsCompilation: no --- a/R/WDI.R +++ b/R/WDI.R @@ -72,8 +72,8 @@ wdi.dl = function(indicator, country, start, end){ daturl = paste("http://api.worldbank.org/countries/", country, "/indicators/", indicator, "?date=",start,":",end, "&per_page=25000", "&format=json", sep = "") - dat = RJSONIO::fromJSON(daturl, nullValue=NA)[[2]] - dat = lapply(dat, function(j) cbind(j$country[[1]], j$country[[2]], j$value, j$date)) + dat = rjson::fromJSON(file = daturl)[[2]] + dat = lapply(dat, function(j) cbind(j$country[[1]], j$country[[2]], ifelse(is.null(j$value), NA, j$value), j$date)) dat = data.frame(do.call('rbind', dat)) for(i in 1:4){ dat[,i] = as.character(dat[,i]) @@ -103,14 +103,14 @@ WDIcache = function(){ # Series series_url = 'http://api.worldbank.org/indicators?per_page=25000&format=json' - series_dat = fromJSON(series_url, nullValue=NA)[[2]] + series_dat = rjson::fromJSON(file = series_url)[[2]] series_dat = lapply(series_dat, function(k) cbind( 'indicator'=k$id, 'name'=k$name, 'description'=k$sourceNote, 'sourceDatabase'=k$source[2], 'sourceOrganization'=k$sourceOrganization)) series_dat = do.call('rbind', series_dat) # Countries country_url = 'http://api.worldbank.org/countries/all?per_page=25000&format=json' - country_dat = fromJSON(country_url, nullValue=NA)[[2]] + country_dat = rjson::fromJSON(file = country_url)[[2]] country_dat = lapply(country_dat, function(k) cbind( 'iso3c'=k$id, 'iso2c'=k$iso2Code, 'country'=k$name, 'region'=k$region[2], 'capital'=k$capitalCity, 'longitude'=k$longitude, 'latitude'=k$latitude, debian/compat0000644000000000000000000000000212164603504010365 0ustar 9 debian/docs0000644000000000000000000000001212213070027010024 0ustar README.md debian/source/0000755000000000000000000000000012164603504010467 5ustar debian/source/format0000644000000000000000000000001412164603504011675 0ustar 3.0 (quilt) debian/control0000644000000000000000000000174412164603504010600 0ustar Source: r-cran-wdi Section: gnu-r Priority: optional Maintainer: Debian Science Team Uploaders: Sébastien Villemot Build-Depends: debhelper (>= 9), r-base-dev, cdbs, r-cran-rjson Standards-Version: 3.9.4 Homepage: http://cran.r-project.org/web/packages/WDI/index.html Vcs-Git: git://anonscm.debian.org/debian-science/packages/r-cran-wdi.git Vcs-Browser: http://anonscm.debian.org/gitweb/?p=debian-science/packages/r-cran-wdi.git Package: r-cran-wdi Architecture: all Depends: ${R:Depends}, r-cran-rjson Description: GNU R package for accessing the World Development Indicators This package gives access to the World Development Indicators (WDI), a database of various development indicators, compiled by the World Bank from officially-recognized international sources. . Note that the package does not contain the data. Instead, it provides a set of functions to download the data from the World Bank's website. debian/rules0000755000000000000000000000007212164603504010246 0ustar #!/usr/bin/make -f include /usr/share/R/debian/r-cran.mk debian/watch0000644000000000000000000000015412164603504010220 0ustar version=3 opts="uversionmangle=s/-/\./" \ http://cran.r-project.org/src/contrib/WDI_([-\d\.]*)\.tar.gz debian/copyright0000644000000000000000000000356212164603504011130 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: World Development Indicators (World Bank) for R Upstream-Contact: Vincent Arel-Bundock Source: http://cran.r-project.org/web/packages/WDI/index.html Files: * Copyright: 2012 Vincent Arel-Bundock License: GPL-3 This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 3. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with Dynare. If not, see . . On Debian systems, the complete text of the GNU General Public License, version 3, can be found in the file `/usr/share/common-licenses/GPL-3'. Files: debian/* Copyright: 2013 Sébastien Villemot License: GPL-3+ This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with Dynare. If not, see . . On Debian systems, the complete text of the GNU General Public License, version 3, can be found in the file `/usr/share/common-licenses/GPL-3'. debian/changelog0000644000000000000000000000061312213071040011026 0ustar r-cran-wdi (2.4-1) unstable; urgency=low * Imported Upstream version 2.4 * rjson.patch: refresh patch * Install README.md under /usr/share/doc/ -- Sébastien Villemot Sun, 08 Sep 2013 14:48:32 +0200 r-cran-wdi (2.2-1) unstable; urgency=low * Initial release. (Closes: #714629) -- Sébastien Villemot Sun, 30 Jun 2013 20:46:07 +0200