Skip to content

Commit

Permalink
migrating from travis-ci to github action
Browse files Browse the repository at this point in the history
  • Loading branch information
AnestisTouloumis committed Jan 22, 2021
1 parent 3853ed2 commit 5c3bca8
Show file tree
Hide file tree
Showing 9 changed files with 119 additions and 56 deletions.
3 changes: 1 addition & 2 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
^.*\.Rproj$
^\.Rproj\.user$
^\.travis\.yml
^README\.Rmd$
^README\.md$
^desktop.ini$
^\.travis\.yml$
^biometrics\.csl$
^codecov\.yml$
^CRAN-RELEASE$
^\.github$
1 change: 1 addition & 0 deletions .github/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.html
84 changes: 84 additions & 0 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
# For help debugging build failures open an issue on the RStudio community with the 'github-actions' tag.
# https://community.rstudio.com/new-topic?category=Package%20development&tags=github-actions
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: windows-latest, r: 'release'}
- {os: macOS-latest, r: 'release'}
- {os: ubuntu-20.04, r: 'release', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}
- {os: ubuntu-20.04, r: 'devel', rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest"}

env:
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
RSPM: ${{ matrix.config.rspm }}
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v2

- uses: r-lib/actions/setup-r@v1
with:
r-version: ${{ matrix.config.r }}

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

- name: Query dependencies
run: |
install.packages('remotes')
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2)
writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version")
shell: Rscript {0}

- name: Cache R packages
if: runner.os != 'Windows'
uses: actions/cache@v2
with:
path: ${{ env.R_LIBS_USER }}
key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-${{ hashFiles('.github/depends.Rds') }}
restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1-

- name: Install system dependencies
if: runner.os == 'Linux'
run: |
while read -r cmd
do
eval sudo $cmd
done < <(Rscript -e 'writeLines(remotes::system_requirements("ubuntu", "20.04"))')
- name: Install dependencies
run: |
remotes::install_deps(dependencies = TRUE)
remotes::install_cran("rcmdcheck")
shell: Rscript {0}

- name: Check
env:
_R_CHECK_CRAN_INCOMING_REMOTE_: false
run: rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran"), error_on = "warning", check_dir = "check")
shell: Rscript {0}

- name: Upload check results
if: failure()
uses: actions/upload-artifact@main
with:
name: ${{ runner.os }}-r${{ matrix.config.r }}-results
path: check
17 changes: 0 additions & 17 deletions .travis.yml

This file was deleted.

2 changes: 0 additions & 2 deletions CRAN-RELEASE

This file was deleted.

2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Package: SimCorMultRes
Type: Package
Title: Simulates Correlated Multinomial Responses
Description: Simulates correlated multinomial responses conditional on a marginal model specification.
Version: 1.7.2
Version: 1.7.3
Depends: R(>= 2.15.0)
Imports:
evd,
Expand Down
2 changes: 1 addition & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ knitr::opts_chunk$set(
# SimCorMultRes: Simulates Correlated Multinomial Responses

[![Github version](`r paste0("https://img.shields.io/badge/GitHub%20-", as.vector(read.dcf('DESCRIPTION')[, 'Version']),"-orange.svg")`)]("commits/master")
[![Travis-CI Build Status](https://travis-ci.org/AnestisTouloumis/SimCorMultRes.svg?branch=master)](https://travis-ci.org/AnestisTouloumis/SimCorMultRes)
[![R-CMD-check](https://github.com/AnestisTouloumis/SimCorMultRes/workflows/R-CMD-check/badge.svg)](https://github.com/AnestisTouloumis/SimCorMultRes/actions)
[![Project Status: Active The project has reached a stable, usable state and is being actively developed.](http://www.repostatus.org/badges/latest/active.svg)](http://www.repostatus.org/#active)
[![Codecov test coverage](https://codecov.io/gh/AnestisTouloumis/SimCorMultRes/branch/master/graph/badge.svg)](https://codecov.io/gh/AnestisTouloumis/SimCorMultRes?branch=master)

Expand Down
61 changes: 29 additions & 32 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@
# SimCorMultRes: Simulates Correlated Multinomial Responses

[![Github
version](https://img.shields.io/badge/GitHub%20-1.7.2-orange.svg)](%22commits/master%22)
[![Travis-CI Build
Status](https://travis-ci.org/AnestisTouloumis/SimCorMultRes.svg?branch=master)](https://travis-ci.org/AnestisTouloumis/SimCorMultRes)
version](https://img.shields.io/badge/GitHub%20-1.7.3-orange.svg)](%22commits/master%22)
[![R-CMD-check](https://github.com/AnestisTouloumis/SimCorMultRes/workflows/R-CMD-check/badge.svg)](https://github.com/AnestisTouloumis/SimCorMultRes/actions)
[![Project Status: Active The project has reached a stable, usable state
and is being actively
developed.](http://www.repostatus.org/badges/latest/active.svg)](http://www.repostatus.org/#active)
Expand All @@ -31,7 +30,7 @@ install.packages("SimCorMultRes")
The source code for the release version of `SimCorMultRes` is available
on CRAN at:

- <https://CRAN.R-project.org/package=SimCorMultRes>
- <https://CRAN.R-project.org/package=SimCorMultRes>

Or you can install the development version of `SimCorMultRes`:

Expand All @@ -43,7 +42,7 @@ devtools::install_github("AnestisTouloumis/SimCorMultRes")
The source code for the development version of `SimCorMultRes` is
available on github at:

- <https://github.com/AnestisTouloumis/SimCorMultRes>
- <https://github.com/AnestisTouloumis/SimCorMultRes>

To use `SimCorMultRes`, you should load the package as follows:

Expand All @@ -60,20 +59,20 @@ regression model for continuous random vectors as proposed by Touloumis

There are five core functions:

- `rbin` to simulate correlated binary responses,
- `rmult.bcl` to simulate correlated nominal multinomial responses,
- `rmult.acl` to simulate correlated ordinal responses under a
- `rbin` to simulate correlated binary responses,
- `rmult.bcl` to simulate correlated nominal multinomial responses,
- `rmult.acl` to simulate correlated ordinal responses under a
marginal adjacent-category logit model,
- `rmult.clm` to simulate correlated ordinal responses under a
- `rmult.clm` to simulate correlated ordinal responses under a
marginal cumulative link model,
- `rmult.clm` to simulate correlated ordinal responses under a
- `rmult.clm` to simulate correlated ordinal responses under a
marginal continuation-ratio link model.

There are also two utility functions:

- `rnorta` for simulating continuous or discrete random vectors with
- `rnorta` for simulating continuous or discrete random vectors with
prescribed marginal distributions using the NORTA method,
- `rsmvnorm` for simulating continuous random vectors from a
- `rsmvnorm` for simulating continuous random vectors from a
multivariate normal distribution.

## Example
Expand Down Expand Up @@ -113,34 +112,32 @@ browseVignettes("SimCorMultRes")

## How to cite

```

To cite R package SimCorMultRes in publications, please use:
To cite R package SimCorMultRes in publications, please use:

Touloumis, A. (2016). Simulating Correlated Binary and Multinomial
Responses under Marginal Model Specification: The SimCorMultRes
Package. The R Journal 8:2, 79-91.
Touloumis, A. (2016). Simulating Correlated Binary and Multinomial
Responses under Marginal Model Specification: The SimCorMultRes
Package. The R Journal 8:2, 79-91.

A BibTeX entry for LaTeX users is
A BibTeX entry for LaTeX users is

@Article{,
title = {Simulating Correlated Binary and Multinomial Responses under
Marginal Model Specification: The SimCorMultRes Package},
author = {Anestis Touloumis},
year = {2016},
journal = {The R Journal},
volume = {8},
number = {2},
pages = {79-91},
url = {https://journal.r-project.org/archive/2016/RJ-2016-034/index.html},
}
```
@Article{,
title = {Simulating Correlated Binary and Multinomial Responses under
Marginal Model Specification: The SimCorMultRes Package},
author = {Anestis Touloumis},
year = {2016},
journal = {The R Journal},
volume = {8},
number = {2},
pages = {79-91},
url = {https://journal.r-project.org/archive/2016/RJ-2016-034/index.html},
}

# References

<div id="refs" class="references">
<div id="refs" class="references csl-bib-body hanging-indent">

<div id="ref-Touloumis2016">
<div id="ref-Touloumis2016" class="csl-entry">

Touloumis, A. (2016) Simulating Correlated Binary and Multinomial
Responses under Marginal Model Specification: The SimCorMultRes Package.
Expand Down
3 changes: 2 additions & 1 deletion inst/NEWS.Rd
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
\name{NEWS}
\title{NEWS file for the \pkg{SimCorMultRes} package}

\section{Changes in Version 1.7.2 (2019-11-02)}{
\section{Changes in Version 1.7.3 (2021-01-22)}{
\itemize{
\item{Migrating from travis-ci to github actions.}
\item{Created NEWS.Rd.}
\item{Fixed ORCID in DESCRIPTION.}
}
Expand Down

0 comments on commit 5c3bca8

Please sign in to comment.