Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@
^bcdata\.Rcheck$
^bcdata.*\.tar\.gz$
^bcdata.*\.tgz$
^\.github$
1 change: 1 addition & 0 deletions .github/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.html
49 changes: 49 additions & 0 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
push:
branches: [main, master]
pull_request:
branches: [main, master]

name: R-CMD-check

jobs:
R-CMD-check:
runs-on: ${{ matrix.config.os }}

name: ${{ matrix.config.os }} (${{ matrix.config.r }})

strategy:
fail-fast: false
matrix:
config:
- {os: macos-latest, r: 'release'}
- {os: windows-latest, r: 'release'}
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
- {os: ubuntu-latest, r: 'release'}
- {os: ubuntu-latest, r: 'oldrel-1'}

env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

steps:
- uses: actions/checkout@v3

- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::rcmdcheck
needs: check

- uses: r-lib/actions/check-r-package@v2
with:
upload-snapshots: true
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ License: What license is it under?
Encoding: UTF-8
LazyData: true
URL: http:johan-rosa.com
RoxygenNote: 7.1.0
RoxygenNote: 7.2.3
Imports:
dplyr,
tidyr,
Expand Down
3 changes: 2 additions & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
exportPattern("^[[:alpha:]]+")
# Generated by roxygen2: do not edit by hand

File renamed without changes.
5 changes: 4 additions & 1 deletion R/ipc.R
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@
#' get_ipc_data(desagregacion = "regiones")

# Funcion para descargar data del IPC
get_ipc_data <- function(desagregacion = "general"){
get_ipc_data <- function(
desagregacion = c("general", "grupos", "regiones", "subyacente", "tnt")
) {
desagregacion <- match.arg(desagregacion)

# Asignando el pipe para usarlo sin cargar dplyr
`%>%` <- magrittr::`%>%`
Expand Down
3 changes: 1 addition & 2 deletions R/pib_sectores.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,9 @@
#'
#' @return Un tibble con la serie del PIB desagregada por sectores de origen.
#'
#' @example
#' @examples
#' # PIB nominal por sectores de origen, serie trimestral desde 1991, base 2007
#' get_pib_sectores(modalidad = "nominal", acumulado = FALSE, homogenea_91 = TRUE)
#'
#' # PIB real por sectores de origen, serie trimestral desde 1991, base 2007
#' get_pib_sectores(modalidad = "nominal", acumulado = FALSE, homogenea_91 = TRUE)
#'
Expand Down
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@

# Packages bcdata

<!-- badges: start -->
[![R-CMD-check](https://github.com/Johan-rosa/bcdata/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/Johan-rosa/bcdata/actions/workflows/R-CMD-check.yaml)
<!-- badges: end -->

The goal of bcdata is to download and import

## Installation

You can install the development version of bcdata from [GitHub](https://github.com/) with:

``` r
# install.packages("devtools")
devtools::install_github("Johan-rosa/bcdata")
```

## Example

This is a basic example which shows you how to solve a common problem:

``` r
library(bcdata)
## basic example code
get_ipc_data("grupos")
```

3 changes: 2 additions & 1 deletion man/get_ipc_data.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions man/get_pib_sectores.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.