Skip to content

Commit

Permalink
readme and citation
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonDedman committed Aug 23, 2023
1 parent 30a60bc commit 49c9658
Show file tree
Hide file tree
Showing 12 changed files with 93 additions and 29 deletions.
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
14 changes: 11 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: gbm.auto
Title: Automated Boosted Regression Tree Modelling and Mapping Suite
Version: 2023.08.15
Version: 2023.08.23
Authors@R: person("Simon", "Dedman", , "simondedman@gmail.com", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-9108-972X"))
Description: Automates delta log-normal boosted regression tree abundance
prediction. Loops through parameters provided (LR (learning rate), TC
Expand All @@ -23,13 +23,21 @@ Imports:
dismo (>= 1.3-14),
dplyr (>= 1.0.9),
gbm (>= 2.1.1),
ggmap (>= 3.0.2),
ggplot2 (>= 3.4.3),
ggspatial (>= 1.1.9),
lifecycle,
lubridate (>= 1.9.2),
mapplots (>= 1.5),
Metrics (>= 0.1.4),
readr (>= 2.1.4),
sf (>= 0.9-7),
shapefiles (>= 0.7),
stars (>= 0.6-3),
starsExtra (>= 0.2.7),
stats (>= 3.3.1),
stringi (>= 1.6.1)
stringi (>= 1.6.1),
tidyselect (>= 1.2.0),
viridis (>= 0.6.4)
Encoding: UTF-8
Language: en-GB
LazyData: true
Expand Down
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ author: "Simon Dedman"
date: "2023-05-25"
output: html_document
---
# v2023.08.23
* citation added, various improvements and cleans, CRAN push

# v2023.08.14
* gbm.factorplot finished, included in gbm.auto, documented. lifecycle package used for function status.

Expand Down
18 changes: 6 additions & 12 deletions R/data.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,9 @@
#' \item{Distance_to_Shore}{Metres, decimal}
#' \item{F_LPUE}{Commercial fishery LPUE in Kg/Hr}
#' \item{Scallop}{Average KwH Scallop effort from logbooks, Marine Institute and MMO combined}
#' \item{MI_Av_E_Hr}{Average effort hours, Marine Institute Scallop VMS,
#' 0.03*0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Av_LPUE}{Average scallop CPUE, Marine Institute Scallop VMS,
#' 0.03*0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Sum_Liv}{Sum of live weight. Average scallop CPUE, Marine Institute Scallop VMS,
#' 0.03*0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Av_E_Hr}{Average effort hours, Marine Institute Scallop VMS, 0.03 x 0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Av_LPUE}{Average scallop CPUE, Marine Institute Scallop VMS, 0.03 x 0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Sum_Liv}{Sum of live weight. Average scallop CPUE, Marine Institute Scallop VMS, 0.03 x 0.02 rectangles, all Irish Sea, 2006-14}
#' \item{Whelk}{MMO Whelk LPUE 2009-12, pivot, polygons to points}
#' \item{MmoAvScKwh}{MMO Scallop Effort 2009-12, pivot, polygons to points. ICES rectangles}
#' \item{Cod_C}{ICES IBTS CPUE of cod caught between 1994 - 2014 large enough to predate upon <= year 1 cuckoo rays}
Expand Down Expand Up @@ -134,12 +131,9 @@
#' \item{Distance_to_Shore}{Metres, decimal}
#' \item{F_LPUE}{Commercial fishery LPUE in Kg/Hr}
#' \item{Scallop}{Average KwH Scallop effort from logbooks, Marine Institute and MMO combined}
#' \item{MI_Av_E_Hr}{Average effort hours, Marine Institute Scallop VMS,
#' 0.03*0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Av_LPUE}{Average scallop CPUE, Marine Institute Scallop VMS,
#' 0.03*0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Sum_Liv}{Sum of live weight. Average scallop CPUE, Marine Institute Scallop VMS,
#' 0.03*0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Av_E_Hr}{Average effort hours, Marine Institute Scallop VMS, 0.03 x 0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Av_LPUE}{Average scallop CPUE, Marine Institute Scallop VMS, 0.03 x 0.02 rectangles, all Irish Sea, 2006-14}
#' \item{MI_Sum_Liv}{Sum of live weight. Average scallop CPUE, Marine Institute Scallop VMS, 0.03 x 0.02 rectangles, all Irish Sea, 2006-14}
#' \item{Whelk}{MMO Whelk LPUE 2009-12, pivot, polygons to points}
#' \item{MmoAvScKwh}{MMO Scallop Effort 2009-12, pivot, polygons to points. ICES rectangles}
#' \item{HubDist}{map calc, distance of grid point to nearest datras point representing it (for preds)}
Expand Down
1 change: 1 addition & 0 deletions R/gbm.mapsf.R
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
#' Default 9.
#' @param shape If mapsource is "gbm.basemap", enter the full path to gbm.basemaps downloaded map,
#' typically Crop_Map.shp, including the .shp. Default NULL.
#' @param expandfactor Extents expansion factor for basemap. default 0.
#' @param colourscale Scale fill colour scheme to use, default "viridis", other option is
#' "gradient".
#' @param colorscale Scale fill colour scheme to use, default NULL, populating this will overwrite
Expand Down
2 changes: 1 addition & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ knitr::opts_chunk$set(
# gbm.auto

<!-- badges: start -->
[![R-CMD-check](https://github.com/SimonDedman/gbm.auto/workflows/R-CMD-check--as-cran/badge.svg)](https://github.com/SimonDedman/gbm.auto/actions)
[![R-CMD-check](https://github.com/SimonDedman/gbm.auto/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/SimonDedman/gbm.auto/actions/workflows/R-CMD-check.yaml)
[![CRAN\_Status\_Badge](https://www.r-pkg.org/badges/version/gbm.auto)](https://cran.r-project.org/package=gbm.auto)
[![CRAN RStudio mirror downloads](https://cranlogs.r-pkg.org/badges/gbm.auto)](https://cran.r-project.org/package=gbm.auto)
<!-- badges: end -->
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<!-- badges: start -->

[![R-CMD-check](https://github.com/SimonDedman/gbm.auto/workflows/R-CMD-check--as-cran/badge.svg)](https://github.com/SimonDedman/gbm.auto/actions)
[![R-CMD-check](https://github.com/SimonDedman/gbm.auto/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/SimonDedman/gbm.auto/actions/workflows/R-CMD-check.yaml)
[![CRAN_Status_Badge](https://www.r-pkg.org/badges/version/gbm.auto)](https://cran.r-project.org/package=gbm.auto)
[![CRAN RStudio mirror
downloads](https://cranlogs.r-pkg.org/badges/gbm.auto)](https://cran.r-project.org/package=gbm.auto)
Expand Down
12 changes: 12 additions & 0 deletions inst/CITATION
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
bibentry(
bibtype = "Article",
title = "Gbm.auto: A software tool to simplify spatial modelling and Marine Protected Area planning",
author = "Dedman, Simon and Officer, Rick and Clarke, Maurice and Reid, David G and Brophy, Deirdre",
journal = "PloS ONE",
year = "2017",
volume = "12",
number = "12",
pages = "e0188955",
doi = "https://doi.org/10.1371/journal.pone.0188955",
url = "https://github.com/SimonDedman/gbm.auto"
)
9 changes: 3 additions & 6 deletions man/Juveniles.Rd

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

2 changes: 2 additions & 0 deletions man/gbm.mapsf.Rd

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

9 changes: 3 additions & 6 deletions man/grids.Rd

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

0 comments on commit 49c9658

Please sign in to comment.