occupancy-and-detection

Estimate site occupancy and detection probability from repeat survey data.

2|Updated Mar 2, 2026
One-click install
npx skills add https://github.com/baratadiego/ecological-agent-skills --skill occupancy-and-detection
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: occupancy-and-detection
Source: https://github.com/baratadiego/ecological-agent-skills/tree/main/skills/occupancy-and-detection
Command: npx skills add https://github.com/baratadiego/ecological-agent-skills --skill occupancy-and-detection

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires numpy, pandas, and includes scripts (resource) components.

What problem does it solve?

Fits single-season and dynamic occupancy models that account for imperfect detection in wildlife survey data. Use this skill when the user mentions occupancy estimation, detection probability, imperfect detection, detection histories, repeated visits, MacKenzie models, psi estimation, dynamic occupancy (colonization/extinction), goodness-of-fit testing (c-hat), site occupancy, or unmarked package analyses.

Core Features & Use Cases

  • Design and analyze occupancy studies with repeated surveys and covariate specification for ψ and p.
  • Produce occupancy (ψ) and detection (p) estimates, model selection results, covariate effects, and goodness-of-fit diagnostics.
  • Guidance for reporting results and planning surveys under closure assumptions.

Quick Start

Provide a detection history matrix and site covariates to run a basic occupancy analysis and obtain ψ and p estimates.

Frequently Asked Questions about occupancy-and-detection

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I estimate site occupancy and detection probability from repeat wildlife surveys?

To estimate site occupancy and detection probability from repeat surveys, you fit occupancy models that account for imperfect detection. This process uses detection history matrices and site covariates to produce psi and p estimates.

What is imperfect detection in occupancy modeling and why does it matter?

Imperfect detection in occupancy modeling means a species is present at a site but missed during a survey. Accounting for it prevents underestimating true site occupancy rates by separating the probability of presence from the probability of detection.

Can I run dynamic occupancy models with colonization and extinction rates in Python?

You can run dynamic occupancy models to estimate colonization and extinction rates using Python interfaces to occupancy modeling tools. These models analyze multi-season detection histories alongside covariates to estimate changing occupancy dynamics.

How do I include site covariates when fitting single-season occupancy models?

To include site covariates in single-season occupancy models, you specify them for both occupancy and detection parameters. This allows the model to estimate how environmental variables influence site occupancy probability and survey-specific detection probability.

How do I perform goodness-of-fit testing and model selection for occupancy models?

Goodness-of-fit testing and model selection for occupancy models involve generating c-hat diagnostics and model selection tables. These outputs assess model adequacy and compare competing models using covariate effects and detection estimates.

Do I need the unmarked package to analyze detection histories and psi estimation?

You can use the unmarked package or Python interfaces to analyze detection histories for psi estimation. These tools provide the necessary functions to process repeat survey data, fit models, and output occupancy estimates.