Installing C libraries in R?

Viewed 31

I am working with the R programming language.

I would like to download this library from github : https://github.com/Datactuariat/Rpostal

I entered the following code in R:

# install from github
devtools::install_github("datactuariat/Rpostal")
library(Rpostal)

After this, I tried one of the demo commands:

# Postal Expand
postal_expand("Quatre vignt douze Ave des Champs-Élysées")

But I get the following error:

Loading required package: jsonlite
Error in system(req, intern = TRUE) : 
  '~/libpostal/src/libpostal' not found

I have a feeling that this is because I did not install the "libpostal C libraries" - but no instructions are provided for doing this in a Windows Environment (I am using Windows).

Can someone please show me what I am doing wrong and how I can fix this problem?

Thanks!

> sessionInfo()
R version 4.1.3 (2022-03-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 22000)

Matrix products: default

locale:
[1] LC_COLLATE=English_Canada.1252  LC_CTYPE=English_Canada.1252    LC_MONETARY=English_Canada.1252
[4] LC_NUMERIC=C                    LC_TIME=English_Canada.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] jsonlite_1.8.0     Rpostal_0.0.0.9000

loaded via a namespace (and not attached):
 [1] compiler_4.1.3    prettyunits_1.1.1 remotes_2.4.2     tools_4.1.3       testthat_3.1.4    digest_0.6.29    
 [7] pkgbuild_1.3.1    pkgload_1.2.4     evaluate_0.15     memoise_2.0.1     lifecycle_1.0.1   rlang_1.0.2      
[13] cli_3.3.0         rstudioapi_0.13   curl_4.3.2        yaml_2.3.5        xfun_0.30         fastmap_1.1.0    
[19] withr_2.5.0       knitr_1.39        desc_1.4.1        fs_1.5.2          devtools_2.4.3    rprojroot_2.0.3  
[25] glue_1.6.2        R6_2.5.1          processx_3.5.3    rmarkdown_2.14    sessioninfo_1.2.2 callr_3.7.0      
[31] purrr_0.3.4       magrittr_2.0.2    ps_1.6.0          ellipsis_0.3.2    htmltools_0.5.2   usethis_2.1.6    
[37] tinytex_0.40      cachem_1.0.6      crayon_1.5.1      brio_1.1.3   
0 Answers
Related