Skip to content

Commit

Permalink
On merging Enrico's pkgdown additions.
Browse files Browse the repository at this point in the history
Merge branch 'main' of github.com:david6marsh/himach into main

# Conflicts:
#	DESCRIPTION
  • Loading branch information
david6marsh committed Oct 12, 2023
2 parents 1fb19cd + fff0a56 commit 8de6e9d
Show file tree
Hide file tree
Showing 14 changed files with 74 additions and 38 deletions.
3 changes: 3 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@
^\.github$
^revdep$
^CRAN-SUBMISSION$
^_pkgdown\.yml$
^docs$
^pkgdown$
48 changes: 48 additions & 0 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# 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]
release:
types: [published]
workflow_dispatch:

name: pkgdown

jobs:
pkgdown:
runs-on: ubuntu-latest
# Only restrict concurrency for non-PR jobs
concurrency:
group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: write
steps:
- uses: actions/checkout@v3

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

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::.
needs: website

- name: Build site
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
shell: Rscript {0}

- name: Deploy to GitHub pages 🚀
if: github.event_name != 'pull_request'
uses: JamesIves/[email protected]
with:
clean: false
branch: gh-pages
folder: docs
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ doc
Meta

/ignore
docs
13 changes: 7 additions & 6 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ Description: For supersonic aircraft, flying subsonic over land,
than on vertical flight profile. For modelling and forecasting, not for planning your
flight!
License: MIT + file LICENSE
URL: https://github.com/david6marsh/himach
URL: https://github.com/david6marsh/himach,
https://dmarsh.github.io/himach/
BugReports: https://github.com/david6marsh/himach/issues
Depends:
R (>= 3.5.0)
Expand All @@ -38,23 +39,23 @@ Imports:
tidyr
Suggests:
airportr,
covr,
cowplot,
knitr,
progress,
rmarkdown,
rnaturalearthdata,
scales,
spelling,
stringr,
testthat (>= 3.0),
units,
utils,
viridis,
covr,
spelling
viridis
VignetteBuilder:
knitr
Config/testthat/edition: 3
Encoding: UTF-8
LazyData: true
Language: en-GB
Config/testthat/edition: 3
LazyData: true
RoxygenNote: 7.2.3
10 changes: 5 additions & 5 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The goal of `himach` ("high Mach") is to support modelling and analysis of the m

In this version of `himach`, 'good' usually means the fastest, so the key indicator is time advantage over flying in a subsonic aircraft.

![Three example routes, including a refuel stop in Anchorage. (Original map: www.naturalearthdata.com)](vignettes/three_routes.png)
![Three example routes, including a refuel stop in Anchorage. (Original map: www.naturalearthdata.com)](man/figures/three_routes.png)

It is not an operational tool. Please don't fly these routes, which do not allow for wind or other atmospheric conditions, and are based on a very simple model of aircraft performance.

Expand Down Expand Up @@ -47,15 +47,15 @@ A second generation of supersonic passenger aircraft is under development (takin

A route from `himach` looks something like this, shown in green on the map. The great-circle route is shown in thin light blue, for comparison. To avoid that the sonic boom reaches land, we have added a buffer around the coast, shown in dark grey.

![Example route between Boston & Frankfurt](vignettes/EDDF_KBOS_time.png)
![Example route between Boston & Frankfurt](man/figures/EDDF_KBOS_time.png)

If we plot a speed view of the same thing, we see that the route maximises the distance over which supersonic speeds may be maintained.

![Example route between Boston & Frankfurt, this time showing speed](vignettes/EDDF_KBOS_speed.png){width=70%}
![Example route between Boston & Frankfurt, this time showing speed](man/figures/EDDF_KBOS_speed.png){width=70%}

Compared to some of the larger subsonic passenger jets, the second generation supersonics are expected to have relatively short range. So finding efficient re-fuelling points is an essential part of the modelling process. This map shows some examples (the results depend on which airports you make available as possible re-fuelling points).

![Example routes, with refuelling points](vignettes/refuel_examples_pacific.png){width=80%}
![Example routes, with refuelling points](man/figures/refuel_examples_pacific.png){width=80%}

Other useful features of `himach` include:

Expand All @@ -67,7 +67,7 @@ Other useful features of `himach` include:
* plotting of route-range envelopes, to help understand routing options (why didn't it stay over the ocean here? why didn't it refuel there?);
* looking at density of flights, when you factor in a forecast where the frequency of flights varies by route and by year (see the advanced vignette).

![Example polar view](vignettes/polar_examples.png)
![Example polar view](man/figures/polar_examples.png)

## Getting Started

Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ In this version of `himach`, ‘good’ usually means the fastest, so the
key indicator is time advantage over flying in a subsonic aircraft.

<figure>
<img src="vignettes/three_routes.png"
<img src="man/figures/three_routes.png"
alt="Three example routes, including a refuel stop in Anchorage. (Original map: www.naturalearthdata.com)" />
<figcaption aria-hidden="true">Three example routes, including a refuel
stop in Anchorage. (Original map: www.naturalearthdata.com)</figcaption>
Expand Down Expand Up @@ -79,7 +79,7 @@ To avoid that the sonic boom reaches land, we have added a buffer around
the coast, shown in dark grey.

<figure>
<img src="vignettes/EDDF_KBOS_time.png"
<img src="man/figures/EDDF_KBOS_time.png"
alt="Example route between Boston &amp; Frankfurt" />
<figcaption aria-hidden="true">Example route between Boston &amp;
Frankfurt</figcaption>
Expand All @@ -89,7 +89,7 @@ If we plot a speed view of the same thing, we see that the route
maximises the distance over which supersonic speeds may be maintained.

<figure>
<img src="vignettes/EDDF_KBOS_speed.png" style="width:70.0%"
<img src="man/figures/EDDF_KBOS_speed.png" style="width:70.0%"
alt="Example route between Boston &amp; Frankfurt, this time showing speed" />
<figcaption aria-hidden="true">Example route between Boston &amp;
Frankfurt, this time showing speed</figcaption>
Expand All @@ -102,7 +102,7 @@ modelling process. This map shows some examples (the results depend on
which airports you make available as possible re-fuelling points).

<figure>
<img src="vignettes/refuel_examples_pacific.png" style="width:80.0%"
<img src="man/figures/refuel_examples_pacific.png" style="width:80.0%"
alt="Example routes, with refuelling points" />
<figcaption aria-hidden="true">Example routes, with refuelling
points</figcaption>
Expand All @@ -129,7 +129,7 @@ Other useful features of `himach` include:
vignette).

<figure>
<img src="vignettes/polar_examples.png" alt="Example polar view" />
<img src="man/figures/polar_examples.png" alt="Example polar view" />
<figcaption aria-hidden="true">Example polar view</figcaption>
</figure>

Expand Down
4 changes: 4 additions & 0 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
url: https://espinielli.github.io/himach/
template:
bootstrap: 5

22 changes: 0 additions & 22 deletions cran-comments.md

This file was deleted.

File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
1 change: 1 addition & 0 deletions man/himach-package.Rd

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

0 comments on commit 8de6e9d

Please sign in to comment.