Package: terradish Type: Package Title: Fast Gradient-Based Optimization of Resistance Surfaces Version: 1.1.0 Date: 2026-10-28 Language: en-US Authors@R: c( person( given = "Bill", family = "Peterman", role = c("aut", "cre"), email = "peterman.73@osu.edu", comment = c(ORCID = "0000-0001-5229-9268") ), person( given = c("Nathaniel", "S."), family = "Pope", role = "aut", email = "nspope@utexas.edu", comment = c(ORCID = "0000-0001-8409-7812") ) ) Description: Maximum likelihood estimation of landscape conductance surfaces from genetic data on raster graphs, using Newton and quasi-Newton optimization with analytic derivatives. Fits log-linear conductance models with optional joint estimation of Gaussian smoothing scales and spline response shapes, linked to pairwise genetic distances through maximum likelihood population effects models or to allele-frequency covariance through a Wishart likelihood on site contrasts, with the same pairwise distance and environment covariates available in both. Provides exact sparse and iterative solvers for large rasters, fixed-domain spatial cross-validation for comparing conductance formulas, and simulation tools for study design. Works with 'terra' objects. Fitting one parameterized conductance surface to genetic data, rather than regressing on separate resistance distances, follows Peterman and Pope (2021) . Background on population-effects models and circuit-based covariance models is provided by Clarke, Rothery and Raybould (2002) and Hanks and Hooten (2013) , respectively. URL: https://github.com/wpeterman/terradish, https://doi.org/10.5281/zenodo.21225711 BugReports: https://github.com/wpeterman/terradish/issues License: BSD_3_clause + file LICENSE Depends: R (>= 4.3.0) Imports: ggplot2, grDevices, landgraph (>= 0.0.3), MASS, Matrix (>= 1.6-2), methods, multiScaleR, nlme, parallel, Rcpp (>= 1.0.4), splines, stats, terra, tools, utils LinkingTo: Matrix (>= 1.6-2), Rcpp, RcppArmadillo, RcppEigen Suggests: adegenet, knitr, numDeriv, patchwork, pkgload, rmarkdown, testthat (>= 3.0.0) VignetteBuilder: knitr Encoding: UTF-8 Config/testthat/edition: 3 Config/roxygen2/version: 8.0.0 Config/pak/sysreqs: libabsl-dev cmake libgdal-dev gdal-bin libgeos-dev make libssl-dev libproj-dev libsqlite3-dev libudunits2-dev Repository: https://wpeterman.r-universe.dev Date/Publication: 2026-10-29 13:53:10 UTC RemoteUrl: https://github.com/wpeterman/terradish RemoteRef: HEAD RemoteSha: 960db5a5e42c5e5245d667e40cc82cb44fd8dc20 NeedsCompilation: yes Packaged: 2026-11-12 16:48:15 UTC; root Author: Bill Peterman [aut, cre] (ORCID: ), Nathaniel S. Pope [aut] (ORCID: ) Maintainer: Bill Peterman