Skip to main content

LocPick

locpick is a Python library for estimating discrete choice models of location decisions — where individuals, households, or firms choose among spatially-defined alternatives (neighborhoods, jobs, housing units, transit stops). These methods have broad applicability but are common in regional land-use and housing market modeling. The package is designed for:

  • Large-scale urban models: 100K+ choosers, 1K+ alternatives
  • Sampling-based estimation: Most alternatives are irrelevant; only a sampled subset is evaluated per chooser
  • Spatial dependence: Nearby alternatives can affect each other or share unobserved attributes (via graph= on any model)
  • Heterogeneous preferences: Mixed logit for random taste variation
  • Nested structure: Nested logit for hierarchical choice (e.g., county → tract → block)
  • JAX-native computation: JIT-compiled kernels, GPU acceleration, automatic differentiation

The package is not a general-purpose ML library. It is specifically for structural econometric models of choice where the likelihood has a closed form (or simulated approximation) and parameters have behavioral interpretations. For more transportation-oriented problems, see larch

Features

LocPick can automate the creation of choice tables for estimation or simulation, using census choice sets, uniform or weighted random sampling of alternatives, generated interaction terms, and cartesian merges. A unique feature is the implementation of spatial choice models, which take one of two forms.

  • The Bhat et al approach is similar to a spatial error model, assuming that nearby alternatives are more similar (closer substitutes).
  • The SAR style approach assumes that the structural utility of each alternative $V$ has a simultaneous autoregressive structure, and is estimated with either PML or GMM

It also provides tools for Monte Carlo simulation of choices given probability distributions from fitted models, with fast algorithms for independent or capacity-constrained choices.

LocPick includes estimators for classic, spatially-correlated, and simultaneous autoregressive:

  • Multinomial Logit
  • Nested Logit
  • Mixed Logit and
  • Mixed/Nested

models, and an internal data pipeline designed around pandas inputs, xarray-backed alignment, and NumPy/JAX-ready arrays.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

locpick-0.0.0.tar.gz (2.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

locpick-0.0.0-py3-none-any.whl (171.6 kB view details)

Uploaded Python 3

File details

Details for the file locpick-0.0.0.tar.gz.

File metadata

  • Download URL: locpick-0.0.0.tar.gz
  • Upload date:
  • Size: 2.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for locpick-0.0.0.tar.gz
Algorithm Hash digest
SHA256 fccda63bfa9a9850dd9a25733bf6bf3ee70c8fa3680ced1b80f2ea55cbb92575
MD5 66d9b06293222824224922fd6c899063
BLAKE2b-256 c2942b20a360ef6a07bde7d846057d263802d766675f11d7ef1db7b8e25c2410

See more details on using hashes here.

Provenance

The following attestation bundles were made for locpick-0.0.0.tar.gz:

Publisher: upload_package.yml on knaaptime/locpick

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file locpick-0.0.0-py3-none-any.whl.

File metadata

  • Download URL: locpick-0.0.0-py3-none-any.whl
  • Upload date:
  • Size: 171.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for locpick-0.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 29504e8085aaa99fc713da4dfe0c6564c9d4cb1c85197093f6f06575f9c59fa2
MD5 69f0b08d4fca26a28a39e23100c98a73
BLAKE2b-256 d6f81fae37266aa4ec333df2c2e7805be71fa8bc0be95cc2d71138f98cc5d5b3

See more details on using hashes here.

Provenance

The following attestation bundles were made for locpick-0.0.0-py3-none-any.whl:

Publisher: upload_package.yml on knaaptime/locpick

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.0.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page