- using R Under development (unstable) (2021-04-09 r80154)
- using platform: x86_64-w64-mingw32 (64-bit)
- using session charset: ISO8859-1
- checking for file 'pct/DESCRIPTION' ... OK
- checking extension type ... Package
- this is package 'pct' version '0.8.0'
- package encoding: UTF-8
- checking package namespace information ... OK
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking if there is a namespace ... OK
- checking for executable files ... OK
- checking for hidden files and directories ... OK
- checking for portable file names ... OK
- checking whether package 'pct' can be installed ... OK
- checking package directory ... OK
- checking 'build' directory ... OK
- checking DESCRIPTION meta-information ... OK
- checking top-level files ... OK
- checking for left-over files ... OK
- checking index information ... OK
- checking package subdirectories ... OK
- checking R files for non-ASCII characters ... OK
- checking R files for syntax errors ... OK
- checking whether the package can be loaded ... OK
- checking whether the package can be loaded with stated dependencies ... OK
- checking whether the package can be unloaded cleanly ... OK
- checking whether the namespace can be loaded with stated dependencies ... OK
- checking whether the namespace can be unloaded cleanly ... OK
- checking loading without being on the library search path ... OK
- checking dependencies in R code ... OK
- checking S3 generic/method consistency ... OK
- checking replacement functions ... OK
- checking foreign function calls ... OK
- checking R code for possible problems ... OK
- checking Rd files ... OK
- checking Rd metadata ... OK
- checking Rd cross-references ... OK
- checking for missing documentation entries ... OK
- checking for code/documentation mismatches ... OK
- checking Rd \usage sections ... OK
- checking Rd contents ... OK
- checking for unstated dependencies in examples ... OK
- checking contents of 'data' directory ... OK
- checking data for non-ASCII characters ... NOTE
Note: found 11 marked UTF-8 strings
- checking LazyData ... OK
- checking data for ASCII and uncompressed saves ... OK
- checking installed files from 'inst/doc' ... OK
- checking files in 'vignettes' ... OK
- checking examples ... ERROR
Running examples in 'pct-Ex.R' failed
The error most likely occurred in:
> ### Name: uptake_pct_govtarget
> ### Title: Calculate cycling uptake for UK 'Government Target' scenario
> ### Aliases: uptake_pct_govtarget uptake_pct_govtarget_2020
> ### uptake_pct_godutch_2020 uptake_pct_govtarget_school2
> ### uptake_pct_godutch_school2
>
> ### ** Examples
>
> distance = 15
> gradient = 2
> logit_pcycle = -3.959 + # alpha
+ (-0.5963 * distance) + # d1
+ (1.866 * sqrt(distance)) + # d2
+ (0.008050 * distance^2) + # d3
+ (-0.2710 * gradient) + # h1
+ (0.009394 * distance * gradient) + # i1
+ (-0.05135 * sqrt(distance) * gradient) # i2
> boot::inv.logit(logit_pcycle)
[1] 0.0107377
> uptake_pct_govtarget(15, 2)
[1] 0.0107377
> l = routes_fast_leeds
> pcycle_scenario = uptake_pct_govtarget(l$length, l$av_incline)
> pcycle_scenario_2020 = uptake_pct_govtarget_2020(l$length, l$av_incline)
> plot(l$length, pcycle_scenario, ylim = c(0, 0.2))
> points(l$length, pcycle_scenario_2020, col = "blue")
>
> # compare with published PCT data:
> l_pct_2020 = get_pct_lines(region = "isle-of-wight")
Warning in CPL_read_ogr(dsn, layer, query, as.character(options), quiet, :
GDAL Error 1: SSL certificate problem: unable to get local issuer certificate
Error: Cannot open "https://github.com/npct/pct-outputs-regional-notR/raw/master/commute/lsoa/isle-of-wight/l.geojson"; The file doesn't seem to exist.
Execution halted
- checking for unstated dependencies in 'tests' ... OK
- checking tests ... ERROR
Running 'skip-heavy.R'
Running 'testthat.R'
Running the tests in 'tests/testthat.R' failed.
Last 13 lines of output:
== Failed tests ================================================================
-- Error (test-get-pct.R:11:3): get_pct_ works ---------------------------------
Error: Cannot open "https://github.com/npct/pct-outputs-regional-notR/raw/master/commute/lsoa/isle-of-wight/z.geojson"; The file doesn't seem to exist.
Backtrace:
x
1. \-pct::get_pct_zones("isle-of-wight") test-get-pct.R:11:2
2. \-pct::get_pct(...)
3. \-sf::read_sf(u_file)
4. +-sf::st_read(...)
5. \-sf:::st_read.character(...)
6. \-sf:::CPL_read_ogr(...)
[ FAIL 1 | WARN 1 | SKIP 1 | PASS 14 ]
Error: Test failures
Execution halted
- checking for unstated dependencies in vignettes ... OK
- checking package vignettes in 'inst/doc' ... OK
- checking running R code from vignettes ... NONE
'cycling-potential-uk.Rmd' using 'UTF-8'... OK
'km-cycled.Rmd' using 'UTF-8'... OK
'pct-international.Rmd' using 'UTF-8'... OK
'pct.Rmd' using 'UTF-8'... OK
'pct_training.Rmd' using 'UTF-8'... OK
'uk-cities.Rmd' using 'UTF-8'... OK
- checking re-building of vignette outputs ... WARNING
Error(s) in re-building vignettes:
--- re-building 'cycling-potential-uk.Rmd' using rmarkdown
--- finished re-building 'cycling-potential-uk.Rmd'
--- re-building 'km-cycled.Rmd' using rmarkdown
Warning in CPL_read_ogr(dsn, layer, query, as.character(options), quiet, :
GDAL Error 1: SSL certificate problem: unable to get local issuer certificate
Quitting from lines 31-37 (km-cycled.Rmd)
Error: processing vignette 'km-cycled.Rmd' failed with diagnostics:
Cannot open "https://github.com/npct/pct-outputs-regional-notR/raw/master/commute/lsoa/oxfordshire/rnet_full.geojson"; The file doesn't seem to exist.
--- failed re-building 'km-cycled.Rmd'
--- re-building 'pct-international.Rmd' using rmarkdown
--- finished re-building 'pct-international.Rmd'
--- re-building 'pct.Rmd' using rmarkdown
Linking to GEOS 3.6.2, GDAL 3.0.4, PROJ 7.0.0
Attaching package: 'dplyr'
The following objects are masked from 'package:stats':
filter, lag
The following objects are masked from 'package:base':
intersect, setdiff, setequal, union
Quitting from lines 115-117 (pct.Rmd)
Error: processing vignette 'pct.Rmd' failed with diagnostics:
Cannot open "https://github.com/npct/pct-outputs-regional-notR/raw/master/commute/msoa/isle-of-wight/c.geojson"; The file doesn't seem to exist.
--- failed re-building 'pct.Rmd'
--- re-building 'pct_training.Rmd' using rmarkdown
Quitting from lines 237-242 (pct_training.Rmd)
Error: processing vignette 'pct_training.Rmd' failed with diagnostics:
Cannot open "https://github.com/npct/pct-outputs-regional-notR/raw/master/commute/msoa/isle-of-wight/z.geojson"; The file doesn't seem to exist.
--- failed re-building 'pct_training.Rmd'
--- re-building 'uk-cities.Rmd' using rmarkdown
Attaching package: 'dplyr'
The following objects are masked from 'package:stats':
filter, lag
The following objects are masked from 'package:base':
intersect, setdiff, setequal, union
Linking to GEOS 3.6.2, GDAL 3.0.4, PROJ 7.0.0
Quitting from lines 45-47 (uk-cities.Rmd)
Error: processing vignette 'uk-cities.Rmd' failed with diagnostics:
Cannot open "https://github.com/npct/pct-outputs-regional-notR/raw/master/commute/lsoa/wales/z.geojson"; The file doesn't seem to exist.
--- failed re-building 'uk-cities.Rmd'
SUMMARY: processing the following files failed:
'km-cycled.Rmd' 'pct.Rmd' 'pct_training.Rmd' 'uk-cities.Rmd'
Error: Vignette re-building failed.
Execution halted
- checking PDF version of manual ... OK
- DONE
Status: 2 ERRORs, 1 WARNING, 1 NOTE