bolster.cli =========== .. py:module:: bolster.cli .. autoapi-nested-parse:: Console script for bolster. Functions --------- .. autoapisummary:: bolster.cli.cli bolster.cli.get_precipitation bolster.cli.water_quality bolster.cli.ni_executive bolster.cli.cinema_listings bolster.cli.ni_house_prices bolster.cli.dva_cmd bolster.cli.gender_pay_gap_cmd bolster.cli.companies_house bolster.cli.ni_elections bolster.cli.daera bolster.cli.daera_waste_cmd bolster.cli.rss bolster.cli.rss_read bolster.cli.rss_nisra_statistics bolster.cli.nisra bolster.cli.nisra_feed bolster.cli.nisra_deaths_cmd bolster.cli.nisra_labour_market_cmd bolster.cli.nisra_births_cmd bolster.cli.nisra_population_cmd bolster.cli.nisra_population_projections_cmd bolster.cli.nisra_marriages_cmd bolster.cli.nisra_civil_partnerships_cmd bolster.cli.nisra_occupancy_cmd bolster.cli.nisra_visitors_cmd bolster.cli.nisra_migration_cmd bolster.cli.nisra_index_of_services_cmd bolster.cli.nisra_index_of_production_cmd bolster.cli.nisra_construction_output_cmd bolster.cli.nisra_ashe_cmd bolster.cli.nisra_composite_index_cmd bolster.cli.nisra_wellbeing_cmd bolster.cli.nisra_cancer_cmd bolster.cli.nisra_emergency_care_cmd bolster.cli.nisra_elective_waiting_times_cmd bolster.cli.nisra_registrar_general_cmd bolster.cli.psni bolster.cli.psni_rtc_cmd bolster.cli.psni_ombudsman_cmd bolster.cli.psni_stop_search_cmd bolster.cli.psni_pace_cmd bolster.cli.nisra_planning_statistics_cmd bolster.cli.nisra_baby_names_cmd bolster.cli.nisra_work_quality_cmd bolster.cli.nisra_public_confidence_cmd bolster.cli.nisra_disease_prevalence_cmd bolster.cli.nisra_qes_cmd bolster.cli.nisra_claimant_count_cmd bolster.cli.psni_crime_cmd bolster.cli.education bolster.cli.education_suspensions_cmd bolster.cli.list_sources Module Contents --------------- .. py:function:: cli(verbose, args=None) Bolster - A comprehensive Python utility library for Northern Ireland and UK data sources. DATA SOURCES ============ Weather & Environment: * get-precipitation UK precipitation maps from Met Office * water-quality NI water quality by postcode/zone Government & Politics: * ni-executive NI Executive historical data * ni-elections NI Assembly election results (2016-2022) * nisra NISRA statistics (deaths, births, population, economic indicators) * psni PSNI statistics (road traffic collisions) * daera DAERA statistics (municipal waste) Business & Property: * companies-house UK Companies House data queries * ni-house-prices NI house price index data Transport: * dva DVA monthly test statistics (vehicle, driver, theory) Employment & Pay: * gender-pay-gap UK Gender Pay Gap reporting data (2017–present) Entertainment & Lifestyle: * cinema-listings Cineworld movie showtimes Utilities: * rss RSS/Atom feed reader with NISRA integration * list-sources Show all available data sources * --version Show version information * --help Show this help message QUICK EXAMPLES ============== bolster water-quality BT1 5GS # Water quality for postcode bolster nisra deaths --latest # Latest NISRA deaths statistics bolster dva --latest --summary # DVA test statistics summary bolster rss nisra-statistics # Browse NISRA publications bolster ni-executive # NI Executive history bolster companies-house farset # Companies at Farset Labs bolster list-sources # Show all data sources bolster --version # Show version information .. note:: Use 'bolster --help' for detailed command options .. py:function:: get_precipitation(bounding_box, order_name, output) Download UK precipitation data from the Met Office and save as an image. This command retrieves precipitation map data from the UK Met Office API and saves it as a PNG image. Requires a Met Office API key and valid order name. Environment Variables: MET_OFFICE_API_KEY: Your Met Office API key (required) MAP_IMAGES_ORDER_NAME: Default order name for precipitation data (optional) .. rubric:: Examples # Download precipitation map for entire UK bolster get-precipitation --order-name "your-order-name" # Download for specific region (Northern Ireland) bolster get-precipitation --bounding-box "-8.5,54.0,-5.0,55.5" --order-name "your-order-name" # Save to custom filename bolster get-precipitation --output "ni_rain.png" --order-name "your-order-name" .. py:function:: water_quality(postcode, zone_code, output_format) Get water quality information for a Northern Ireland postcode or zone. Provides water quality data including hardness classification, chemical parameters, and compliance information from Northern Ireland Water. .. rubric:: Examples bolster water-quality BT1 5GS # Lookup by postcode bolster water-quality --zone-code BALM # Lookup by zone code bolster water-quality BT7 --format json # JSON output .. py:function:: ni_executive(output_format, save) Get Northern Ireland Executive composition and dissolution data. Retrieves historical data about NI Executive periods including establishment dates, dissolution dates, duration, and interregnum periods. .. rubric:: Examples bolster ni-executive # Display as table bolster ni-executive --format json # JSON output bolster ni-executive --save executive.csv # Save to CSV file .. py:function:: cinema_listings(site_code, screening_date, output_format) Get current movie listings from Cineworld cinema. Retrieves movie showtimes and information for a specific Cineworld location. Default location is Belfast (site code 117). .. rubric:: Examples bolster cinema-listings # Belfast, today bolster cinema-listings --site-code 105 # Different location bolster cinema-listings --date 2024-03-20 # Specific date .. py:function:: ni_house_prices(output_format, save) Get Northern Ireland house price index data. Downloads and processes the latest NI house price statistics from official sources, including price trends by property type, region, and time period. .. rubric:: Examples bolster ni-house-prices # Display as CSV bolster ni-house-prices --format json # JSON output bolster ni-house-prices --save prices.csv # Save to file .. py:function:: dva_cmd(latest, test_type, year, output_format, force_refresh, save, summary) DVA (Driver & Vehicle Agency) Monthly Test Statistics. Retrieves monthly test statistics from the NI Driver & Vehicle Agency including: - Vehicle tests (MOT-style tests) - Driver tests (practical driving tests) - Theory tests Data available from April 2014 to present. .. rubric:: Examples bolster dva --latest # All test types bolster dva --latest --test-type vehicle # Just vehicle tests bolster dva --latest --year 2024 # Filter by year bolster dva --latest --summary # Quick summary dashboard bolster dva --latest --format json --save tests.json Source: https://www.infrastructure-ni.gov.uk/publications/type/statistics .. py:function:: gender_pay_gap_cmd(year, all_years, postcode_prefix, output_format, save, summary) UK Gender Pay Gap Reporting Data. All UK employers with 250+ employees are required to report their gender pay gap annually. Data is available from 2017 to present. Filter by postcode prefix to focus on a specific region — e.g. 'BT' for Northern Ireland, 'EH' for Edinburgh, 'M' for Manchester. .. rubric:: Examples bolster gender-pay-gap --postcode-prefix BT # NI employers, latest year bolster gender-pay-gap --year 2024 # All UK employers, 2024 bolster gender-pay-gap --all-years --postcode-prefix BT # NI trend data bolster gender-pay-gap --postcode-prefix BT --summary # NI summary stats bolster gender-pay-gap --year 2024 --format json --save gpg_2024.json Source: https://gender-pay-gap.service.gov.uk/viewing/download .. py:function:: companies_house(query, output_format, save) Query UK Companies House data for company information. Search for companies by name or get information about companies that might be associated with Farset Labs (Belfast hackerspace). .. rubric:: Examples bolster companies-house "farset" # Search for companies with 'farset' bolster companies-house farset # Search without quotes bolster companies-house --format json # JSON output bolster companies-house --save companies.csv # Save results .. py:function:: ni_elections(election_year, output_format, save) Get Northern Ireland Assembly election results (2016-2022). Retrieve detailed election results including candidates, parties, constituencies, and vote counts for NI Assembly elections. .. rubric:: Examples bolster ni-elections # All election results bolster ni-elections --election-year 2022 # 2022 results only bolster ni-elections --format json # JSON output bolster ni-elections --save elections.csv # Save to file .. py:function:: daera() DAERA (Department of Agriculture, Environment and Rural Affairs) statistics. Commands for accessing Northern Ireland environmental and agricultural statistics published by DAERA. .. py:function:: daera_waste_cmd(force_refresh, council, financial_year, summary, save, output_format) DAERA NI LAC Municipal Waste statistics. Downloads the latest quarterly waste management time-series from DAERA, covering all NI council areas from 2006/07 onwards. Examples:  bolster daera waste # All waste statistics bolster daera waste --council Belfast # Filter by council bolster daera waste --financial-year 2024/25 # Latest year bolster daera waste --summary # Summary only bolster daera waste --save waste.csv # Save to CSV .. py:function:: rss() RSS/Atom feed reading commands. Tools for reading and parsing RSS/Atom feeds with beautiful terminal formatting. Includes generic feed reader and specialized commands for NISRA statistics. .. py:function:: rss_read(feed_url, limit, title_filter, after_date, before_date, format) Read and display RSS/Atom feeds with beautiful formatting. Fetches and parses RSS or Atom feeds from any URL, displaying entries with rich formatting in the terminal. Supports filtering by title and date range. :param feed_url: URL of the RSS or Atom feed to read :param limit: Maximum number of entries to display :param title_filter: Filter entries by title keyword :param after_date: Show only entries after this date :param before_date: Show only entries before this date :param format: Output format (rich, json, csv) .. rubric:: Examples # Display NISRA statistics feed bolster rss-feed "https://www.gov.uk/search/research-and-statistics.atom" # Filter by title keyword bolster rss-feed URL --title-filter "health" # Limit to recent entries bolster rss-feed URL --limit 10 --after-date 2024-01-01 .. note:: Output formats: - rich: Beautiful terminal output with colors and formatting (default) - json: Machine-readable JSON output - csv: Comma-separated values for spreadsheet import .. py:function:: rss_nisra_statistics(limit, title_filter, after_date, order, format) Browse NISRA (Northern Ireland Statistics and Research Agency) publications. Fetches and displays recent research and statistics publications from NISRA via the GOV.UK website. Includes reports on demographics, health, economy, labour market, crime, and lifestyle surveys. :param limit: Maximum number of entries to display :param title_filter: Filter entries by title keyword :param after_date: Show only entries after this date :param order: Sort order for entries (newest, oldest) :param format: Output format (rich, json, csv) .. rubric:: Examples # Show recent NISRA publications bolster nisra-statistics # Find health-related statistics bolster nisra-statistics --title-filter "health" # Get oldest publications first bolster nisra-statistics --order oldest --limit 10 # Export to CSV bolster nisra-statistics --format csv > nisra.csv .. note:: Publication types include: - Labour Market Statistics - Population & Demographics - Health & Social Care - Crime & Justice Statistics - Economic Statistics - Lifestyle & Wellbeing Surveys Output formats: - rich: Beautiful terminal output with colors (default) - json: Machine-readable JSON format - csv: Spreadsheet-compatible CSV format .. py:function:: nisra() NISRA (Northern Ireland Statistics and Research Agency) data sources. Access official statistics and research publications from NISRA including: - Weekly death registrations with demographic breakdowns - Labour market statistics (employment, economic inactivity) - Economic indicators (Index of Production, Index of Services, Construction Output, Composite Index) - Population estimates, births, marriages, migration - Tourism (accommodation occupancy, visitor statistics) - Cancer and emergency care waiting times All data is sourced directly from NISRA publications and cached locally for performance. Use --force-refresh to bypass cache and download fresh data. .. py:function:: nisra_feed(limit, title_filter, days, check_coverage) Show recent NISRA publications from RSS feed. Useful for discovering new datasets and checking for updates. .. rubric:: Examples bolster nisra feed # Recent 20 publications bolster nisra feed -n 50 # More entries bolster nisra feed -f tourism # Filter by title bolster nisra feed --days 7 # Last week only bolster nisra feed --check-coverage # Show implementation status .. py:function:: nisra_deaths_cmd(dimension, output_format, force_refresh, save) NISRA Weekly Deaths Statistics. Retrieves weekly death registrations in Northern Ireland with breakdowns by: - Totals (COVID-19 deaths, flu/pneumonia deaths, excess deaths) - Demographics (age, sex) - Geography (Local Government Districts) - Place of death (hospital, home, care home, etc.) Examples: --------- Get COVID-19 and flu/pneumonia deaths:: bolster nisra deaths --dimension totals Get latest demographics breakdown as CSV:: bolster nisra deaths --dimension demographics Get all dimensions as JSON:: bolster nisra deaths --dimension all --format json Save totals data to analyze COVID trends:: bolster nisra deaths --dimension totals --save deaths_totals.csv Force refresh cached data:: bolster nisra deaths --force-refresh Notes: ------ - Based on registration date, not death occurrence date - Most deaths registered within 5 days in Northern Ireland - Weekly files are provisional and subject to revision - Dimensions are NOT cross-tabulated in source data - COVID-19/flu deaths are NOT broken down by age/sex in source - Excess deaths calculated using multiple methodologies Dimensions ---------- totals Weekly totals with COVID-19, flu/pneumonia, excess deaths demographics Age and sex breakdown (Total/Male/Female × age ranges) geography Local Government Districts (11 LGDs) place Place of death (Hospital, Home, Care Home, Hospice, Other) all All dimensions (returns separate tables) Source ------ https://www.nisra.gov.uk/statistics/death-statistics/weekly-death-registrations-northern-ireland .. py:function:: nisra_labour_market_cmd(dimension, table_deprecated, output_format, force_refresh, save) NISRA Labour Force Survey Statistics. Retrieves Labour Force Survey (LFS) data for Northern Ireland including: - Employment by age band and sex (quarterly) - Economic inactivity rates and numbers with historical time series (quarterly) - Employment by Local Government District (annual) The LFS is a sample survey of households providing labour force statistics using internationally agreed concepts and definitions. Examples: --------- Get latest employment data by age and sex:: bolster nisra labour-market --dimension employment Get economic inactivity time series (2012-2025):: bolster nisra labour-market --dimension economic_inactivity Get employment by Local Government District (annual):: bolster nisra labour-market --dimension lgd Get all dimensions as JSON:: bolster nisra labour-market --dimension all --format json Save employment data to analyze age distribution:: bolster nisra labour-market --dimension employment --save employment.csv Force refresh cached data:: bolster nisra labour-market --force-refresh Notes: ------ - Survey data with sampling variability (see NISRA notes on confidence intervals) - Quarterly publications covering 3-month rolling periods - Some estimates based on small samples (indicated by shading in source) - Estimates <3 suppressed for disclosure control - Not seasonally adjusted - Working age: 16-64 for both males and females Tables ------ employment Employment by age band and sex (Table 2.15) • Percentage distribution across age groups • Total employment numbers by sex • Quarterly snapshot data economic_inactivity Economic inactivity by sex (Table 2.21) • Numbers economically inactive by sex • Economic inactivity rates (percentages) • Historical time series (2012-2025 for same quarter) • Allows year-over-year comparisons lgd Employment by Local Government District (Table 1.16a) • Employment statistics for all 11 NI LGDs • Population 16+, employment rates, economic activity • Annual data only (published separately) all All quarterly tables (excludes LGD annual data) Definitions ----------- Employed Did ≥1 hour paid work in reference week, or has job temporarily away from Unemployed Not employed, actively seeking work, available to start within 2 weeks Economically Inactive Not employed and not seeking work (students, retired, caring for family, long-term sick/disabled, discouraged workers, etc.) Source ------ https://www.nisra.gov.uk/statistics/labour-market-and-social-welfare .. py:function:: nisra_births_cmd(event_type, output_format, force_refresh, save) NISRA Monthly Birth Registrations Statistics. Retrieves monthly birth registration data for Northern Ireland including: - Births by month of registration (when officially registered) - Births by month of occurrence (when actually born) - Breakdown by sex (Persons, Male, Female) Birth registration data are based on mother's residence at time of birth. Most births are registered within 42 days in Northern Ireland. Examples: --------- Get latest births by registration date:: bolster nisra births --event-type registration Get latest births by occurrence (actual birth date):: bolster nisra births --event-type occurrence Get both registration and occurrence data:: bolster nisra births --event-type both Save registration data to file:: bolster nisra births --event-type registration --save births_reg.csv Get data as JSON:: bolster nisra births --event-type both --format json Force refresh cached data:: bolster nisra births --force-refresh Notes: ------ - Monthly time series from 2006 to present - Final data for years up to and including 2024 - Provisional and subject to change for current year - Registration data lags occurrence data by ~1-2 months - COVID-19 Note: April-May 2020 registration data disrupted by lockdown (registration offices closed), but occurrence data remains normal Event Types ----------- registration Births by month they were officially registered • Reflects administrative processing dates • Can be affected by office closures (e.g., COVID-19) • Latest data may be 1-2 months more recent than occurrence occurrence Births by month they actually occurred • Reflects actual birth dates • More stable measure of birth patterns • Limited to births already registered both Returns both registration and occurrence data • Useful for comparing registration patterns vs birth patterns • Helps identify registration delays/backlogs Returns: -------- DataFrame - month: First day of month (datetime) - sex: Persons (total), Male, or Female - births: Number of births Source ------ https://www.nisra.gov.uk/statistics/births-deaths-and-marriages/births .. py:function:: nisra_population_cmd(area, year, output_format, force_refresh, save) NISRA Mid-Year Population Estimates. Retrieves annual mid-year population estimates for Northern Ireland with breakdowns by: - Geography (NI overall, Parliamentary Constituencies, Health and Social Care Trusts) - Sex (All persons, Males, Females) - Age (5-year age bands: 00-04, 05-09, ..., 90+) - Year (1971-present for NI overall, 2021-present for sub-geographies) Mid-year estimates are referenced to June 30th of each year. Examples: --------- Get latest NI overall population:: bolster nisra population Get all geographic areas:: bolster nisra population --area all Get specific year:: bolster nisra population --year 2024 Get Parliamentary Constituencies:: bolster nisra population --area "Parliamentary Constituencies (2024)" Save to file:: bolster nisra population --save population.csv Get as JSON:: bolster nisra population --format json Notes: ------ - Published annually ~6 months after reference date - Reference date: June 30th of each year - Historical data for NI overall from 1971 - Sub-geography data from 2021 onwards - Age bands: 5-year groups (00-04, 05-09, ..., 85-89, 90+) - Also includes custom age bands and broad age groups Geographic Areas ---------------- Northern Ireland NI overall (1971-present) Parliamentary Constituencies (2024) 2024 parliamentary constituencies (2021-present) Health and Social Care Trusts Health & Social Care Trusts (2021-present) all All geographic breakdowns Returns: -------- DataFrame - area, area_code, area_name: Geographic identifiers - year: Reference year (mid-year estimate as of June 30th) - sex: All persons, Males, or Females - age_5: 5-year age band - age_band, age_broad: Alternative age groupings - population: Mid-year estimate Source ------ https://www.nisra.gov.uk/statistics/people-and-communities/population .. py:function:: nisra_population_projections_cmd(lgd, lgd_name, start_year, end_year, output_format, force_refresh, save) NISRA Population Projections for Northern Ireland. By default returns NI-level principal projections (2024-based, to 2074). Use --lgd to get LGD sub-area projections (2022-based, 11 districts, to 2047). \b .. rubric:: Examples bolster nisra population-projections bolster nisra population-projections --start-year 2025 --end-year 2035 bolster nisra population-projections --lgd bolster nisra population-projections --lgd --lgd-name Belfast bolster nisra population-projections --lgd --lgd-name N09000003 .. py:function:: nisra_marriages_cmd(year, output_format, force_refresh, save) NISRA Monthly Marriage Registrations Statistics. Retrieves monthly marriage registration data for Northern Ireland. Marriage registrations represent when the marriage was registered, not when the ceremony occurred. The data is published monthly with provisional figures for the current year and final figures for previous years. Examples: --------- Get latest marriages data:: bolster nisra marriages Filter for a specific year:: bolster nisra marriages --year 2024 Save to file:: bolster nisra marriages --save marriages.csv Get data as JSON:: bolster nisra marriages --format json Force refresh cached data:: bolster nisra marriages --force-refresh Notes: ------ - Monthly time series from 2006 to present - Final data for years up to and including 2024 - Provisional and subject to change for current year - COVID-19 Note: 2020 shows dramatic impact on marriages (April: 14, May: 4 marriages during strict lockdown) Seasonal Patterns ----------------- Summer months (June-September) are peak wedding season: • August typically has the highest number of marriages • June-September account for ~40% of annual marriages • January-February typically have the lowest numbers Returns: -------- DataFrame - date: First day of month (datetime) - year: Year of registration - month: Month name - marriages: Number of marriage registrations Source ------ https://www.nisra.gov.uk/statistics/births-deaths-and-marriages/marriages .. py:function:: nisra_civil_partnerships_cmd(latest, year, output_format, force_refresh, save, summary) NISRA Monthly Civil Partnership Registrations Statistics. Retrieves monthly civil partnership registration data for Northern Ireland. Civil partnerships became legal in Northern Ireland in December 2005. The data is published monthly with provisional figures for the current year and final figures for previous years. .. rubric:: Examples Get latest civil partnerships data:: bolster nisra civil-partnerships --latest Filter for a specific year:: bolster nisra civil-partnerships --latest --year 2024 Show annual summary:: bolster nisra civil-partnerships --latest --summary Save to file:: bolster nisra civil-partnerships --latest --save civil_partnerships.csv Data Notes: - Monthly time series from 2006 to present - Typically 80-120 civil partnerships per year - Numbers generally lower than marriages (5-10 per month average) - COVID-19 Note: 2020-2021 shows reduced registrations :returns: - date: First day of month (datetime) - year: Year of registration - month: Month name - civil_partnerships: Number of civil partnership registrations :rtype: DataFrame with columns .. note:: Source: https://www.nisra.gov.uk/statistics/births-deaths-and-marriages/civil-partnerships .. py:function:: nisra_occupancy_cmd(latest, year, accommodation, data_type, output_format, force_refresh, save, summary, compare) NISRA Monthly Accommodation Occupancy Statistics. Retrieves monthly occupancy data for Northern Ireland from the Tourism Statistics Branch. Supports both hotel and SSA (Small Service Accommodation - B&Bs, guest houses) data. :param accommodation: Type of accommodation: ``hotel`` (Hotels, 2011-present, ~65% avg occupancy), ``ssa`` (Small Service Accommodation: B&Bs/guest houses, 2013-present, ~33% avg), or ``combined`` (both types with accommodation_type column). :type accommodation: str :param data_type: Data to retrieve: ``rates`` (room and bed occupancy rates, 0-1 scale) or ``sold`` (number of rooms and beds sold monthly). :type data_type: str :param .. rubric:: Examples: :param Get latest hotel occupancy rates (default)::: bolster nisra occupancy --latest :param Get SSA (B&B/guest house) occupancy::: bolster nisra occupancy --latest --accommodation ssa :param Get combined data with accommodation type::: bolster nisra occupancy --latest --accommodation combined :param Compare hotel vs SSA by year::: bolster nisra occupancy --compare :param Get rooms/beds sold data::: bolster nisra occupancy --latest --data-type sold :param Filter for a specific year::: bolster nisra occupancy --latest --year 2024 :param Show summary by year::: bolster nisra occupancy --latest --summary :param Save to file::: bolster nisra occupancy --latest --save occupancy.csv :param .. rubric:: Notes: :param - Hotel data: :type - Hotel data: 2011-present (~65% average room occupancy) :param - SSA data: :type - SSA data: 2013-present (~33% average room occupancy) :param - Room occupancy is typically higher than bed occupancy: :param - COVID-19 Note: (all accommodation closed March-July 2020, Oct-Dec 2020, Jan-May 2021) :type - COVID-19 Note: 2020-2021 shows dramatic impact on tourism :param .. rubric:: Seasonal Patterns: :param Summer months (June-September) are peak tourism season: :param - August typically has the highest occupancy (~80% hotel: :param ~55% SSA): :param - July-September are consistently strong: :param - January-February typically have the lowest occupancy: :param .. rubric:: Returns: :param DataFrame (rates): :param - date: :type - date: First day of month (datetime) :param - year: :type - year: Year :param - month: :type - month: Month name :param - room_occupancy: :type - room_occupancy: Room occupancy rate (0-1) :param - bed_occupancy: :type - bed_occupancy: Bed occupancy rate (0-1) :param - accommodation_type: :type - accommodation_type: (combined only) 'hotel' or 'ssa' :param DataFrame (sold): :param - date: :type - date: First day of month (datetime) :param - year: :type - year: Year :param - month: :type - month: Month name :param - rooms_sold: :type - rooms_sold: Number of rooms sold :param - beds_sold: :type - beds_sold: Number of beds sold :param .. rubric:: Source: :param https: :type https: //www.nisra.gov.uk/statistics/tourism/occupancy-surveys .. py:function:: nisra_visitors_cmd(latest, market, output_format, force_refresh, save, summary, compare) NISRA Quarterly Visitor Statistics (Trips, Nights, Expenditure). Retrieves quarterly visitor statistics for Northern Ireland from NISRA, showing overnight trips, nights spent, and visitor expenditure by market origin. :param latest: Get the most recent visitor statistics data :param market: Filter by visitor market (gb, europe, north-america, overseas, roi, ni, total, all) :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) :param summary: Show summary statistics only :param compare: Compare domestic vs external visitors Markets: * gb - Great Britain (largest external market) * europe - Other Europe (excluding GB and ROI) * north-america - North America (USA and Canada) * overseas - Other overseas (Asia, Oceania, etc.) * roi - Republic of Ireland * ni - NI Residents (domestic tourism) * total - All markets combined * all - Show all markets (default) .. rubric:: Examples Get latest visitor statistics:: bolster nisra visitors --latest Show market summary with per-trip metrics:: bolster nisra visitors --latest --summary Compare domestic vs external visitors:: bolster nisra visitors --latest --compare Get Great Britain visitors only:: bolster nisra visitors --latest --market gb Save to file:: bolster nisra visitors --latest --save visitors.csv Data Insights: - GB is typically the largest external market (~30% of trips, ~38% of spend) - ROI visitors growing rapidly (up 32% trips, 68% spend YoY in 2025) - NI residents account for ~31% of trips but only ~17% of expenditure - External visitors spend 2-4x more per trip than NI residents - "Other Overseas" (long-haul) has highest spend per trip (~£540) .. note:: Source: https://www.nisra.gov.uk/publications/quarterly-tourism-statistics-publications .. py:function:: nisra_migration_cmd(year, start_year, end_year, output_format, force_refresh, save, summary) NISRA Migration Estimates (Derived from Demographic Components). Calculates net migration using the demographic accounting equation: Net Migration = Population Change - Natural Change Net Migration = ΔPopulation - (Births - Deaths) This combines data from: - Mid-year population estimates - Monthly birth registrations (occurrence data) - Historical death registrations The demographic equation must hold: Pop(t+1) = Pop(t) + Births - Deaths + Migration :param year: Filter data for specific year :param start_year: Start year for data range :param end_year: End year for data range :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) :param summary: Show summary statistics only .. rubric:: Examples Get all migration data:: bolster nisra migration Filter for specific year:: bolster nisra migration --year 2024 Show summary statistics for 2010-2024:: bolster nisra migration --start-year 2010 --summary Save to file:: bolster nisra migration --save migration.csv Get data as JSON:: bolster nisra migration --format json Force refresh all source data:: bolster nisra migration --force-refresh Data Notes: - Coverage: 2011-2024 (limited by historical deaths data) - Derived migration includes net effect of international and internal migration - Also captures measurement error and timing differences between sources - Demographic equation validated for all years (ΔPop = Births - Deaths + Migration) Key Findings: - 2023: Highest net immigration (+7,225) - 2024: Strong immigration continues (+6,107) - 2013: Highest net emigration (-2,124) - Average 2011-2024: +2,082 per year - 9 years with net immigration, 5 with net emigration :returns: - year: Year - population_start, population_end: Mid-year population estimates - births, deaths: Annual totals - natural_change: Births - Deaths - population_change: Year-over-year change - net_migration: Derived migration estimate - migration_rate: Per 1,000 population :rtype: DataFrame with columns .. note:: Combines three NISRA data sources: - Population: https://www.nisra.gov.uk/statistics/people-and-communities/population - Births: https://www.nisra.gov.uk/statistics/births-deaths-and-marriages/births - Deaths: https://www.nisra.gov.uk/statistics/births-deaths-and-marriages/deaths .. py:function:: nisra_index_of_services_cmd(year, quarter, start_year, end_year, output_format, force_refresh, save, summary, growth) NISRA Index of Services (IOS) - Quarterly Economic Indicator. Measures output in Northern Ireland's services sector, including business services, wholesale/retail trade, transport, and other services. Seasonally adjusted quarterly data from Q1 2005 to present. :param year: Filter by specific year :param quarter: Filter by specific quarter (Q1, Q2, Q3, Q4) :param start_year: Start year for filtering :param end_year: End year for filtering :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) :param summary: Show summary statistics only :param growth: Include year-on-year growth rates .. rubric:: Examples Get all Index of Services data:: bolster nisra index-of-services Filter for specific year:: bolster nisra index-of-services --year 2024 Get specific quarter:: bolster nisra index-of-services --year 2025 --quarter Q3 Show summary statistics for 2020-2025:: bolster nisra index-of-services --start-year 2020 --summary Include year-on-year growth rates:: bolster nisra index-of-services --growth Save to file:: bolster nisra index-of-services --save ios.csv Data Notes: - Coverage: Q1 2005 - Q3 2025 (quarterly) - Seasonally adjusted values - Index values (100 = base period) - Includes NI and UK comparator data - Published ~3 months after quarter end :returns: - date: First day of quarter - quarter: Quarter code (Q1, Q2, Q3, Q4) - year: Year - ni_index: Northern Ireland services index value - uk_index: UK services index value - ni_growth_rate: YoY % change (if --growth specified) - uk_growth_rate: YoY % change (if --growth specified) :rtype: DataFrame with columns .. note:: Source: NISRA Economic & Labour Market Statistics Branch https://www.nisra.gov.uk/statistics/economic-output/index-services .. py:function:: nisra_index_of_production_cmd(year, quarter, start_year, end_year, output_format, force_refresh, save, summary, growth) NISRA Index of Production (IOP) - Quarterly Economic Indicator. Measures output in Northern Ireland's production industries, including manufacturing, mining, and utilities. Seasonally adjusted quarterly data from Q1 2005 to present. :param year: Filter data for specific year :param quarter: Filter data for specific quarter (e.g., 'Q1', 'Q2') :param start_year: Start year for summary statistics :param end_year: End year for summary statistics :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) :param summary: Show summary statistics only :param growth: Include year-on-year growth rates .. rubric:: Examples Get all Index of Production data:: bolster nisra index-of-production Filter for specific year:: bolster nisra index-of-production --year 2024 Get specific quarter:: bolster nisra index-of-production --year 2025 --quarter Q3 Show summary statistics:: bolster nisra index-of-production --start-year 2020 --summary Include growth rates:: bolster nisra index-of-production --growth Save as JSON:: bolster nisra index-of-production --format json --save iop.json Data Notes: - Coverage: Q1 2005 - Q3 2025 (quarterly) - Seasonally adjusted values - Index values (100 = base period) - Includes NI and UK comparator data - Production industries have faced long-term challenges :returns: - date: First day of quarter - quarter: Quarter code (Q1, Q2, Q3, Q4) - year: Year - ni_index: Northern Ireland production index value - uk_index: UK production index value - ni_growth_rate: YoY % change (if --growth specified) - uk_growth_rate: YoY % change (if --growth specified) :rtype: DataFrame with columns .. note:: Source: NISRA Economic & Labour Market Statistics Branch https://www.nisra.gov.uk/statistics/economic-output/index-production .. py:function:: nisra_construction_output_cmd(year, quarter, start_year, end_year, output_format, force_refresh, save, summary, growth) NISRA Construction Output Statistics - Quarterly Economic Indicator. Measures volume and value of construction output in Northern Ireland across all work, new work, and repair & maintenance. Chained volume measure data (base year 2022=100) from Q2 2000 to present. :param year: Filter data for specific year :param quarter: Filter data for specific quarter (e.g., 'Q1', 'Q2') :param start_year: Start year for summary statistics :param end_year: End year for summary statistics :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) :param summary: Show summary statistics only :param growth: Include year-on-year growth rates .. rubric:: Examples Get all Construction Output data:: bolster nisra construction-output Filter for specific year:: bolster nisra construction-output --year 2024 Get specific quarter:: bolster nisra construction-output --year 2025 --quarter Q2 Show summary statistics for 2020-2025:: bolster nisra construction-output --start-year 2020 --summary Include year-on-year growth rates:: bolster nisra construction-output --growth Save to file:: bolster nisra construction-output --save construction.csv Data Notes: - Coverage: Q2 2000 - Q2 2025 (quarterly) - Base year: 2022 = 100 (chained volume measure) - All Work: Non-seasonally adjusted (NSA) - New Work: Non-seasonally adjusted (NSA) - Repair & Maintenance: Seasonally adjusted (SA) - Published ~3 months after quarter end :returns: - date: First day of quarter - quarter: Quarter code (Q1, Q2, Q3, Q4) - year: Year - all_work_index: Total construction output index (NSA) - new_work_index: New construction work index (NSA) - repair_maintenance_index: Repair & maintenance index (SA) - \*_yoy_growth: YoY % change (if --growth specified) :rtype: DataFrame with columns .. note:: Source: NISRA Economic & Labour Market Statistics Branch https://www.nisra.gov.uk/statistics/economic-output/construction-output-statistics .. py:function:: nisra_ashe_cmd(metric, dimension, basis, year, output_format, force_refresh, save, growth) NISRA Annual Survey of Hours and Earnings (ASHE) - Employee Earnings Statistics. Annual survey measuring employee earnings in Northern Ireland across multiple dimensions including employment type, sector, geography, occupation, and industry. Data from April of each year, published in October. :param metric: Type of earnings metric (weekly, hourly, or annual) :param dimension: Data dimension (timeseries, geography, sector, real-earnings, real-earnings-change, real-earnings-index, occupation-change, industry-change, pay-distribution, pay-distribution-by-classification) :param basis: Geographic basis (workplace or residence, for geography dimension only) :param year: Filter data for specific year :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) :param growth: Include year-on-year growth rates (timeseries only) .. rubric:: Examples Get weekly earnings timeseries (1997-2025):: bolster nisra ashe Get hourly earnings timeseries:: bolster nisra ashe --metric hourly Get annual earnings timeseries:: bolster nisra ashe --metric annual Get geographic earnings by workplace:: bolster nisra ashe --dimension geography Get geographic earnings by residence:: bolster nisra ashe --dimension geography --basis residence Get public vs private sector comparison:: bolster nisra ashe --dimension sector Include year-on-year growth rates:: bolster nisra ashe --growth Filter for specific year:: bolster nisra ashe --year 2025 Save to file:: bolster nisra ashe --save earnings.csv --format csv Data Notes: - Coverage: April 1997 - 2025 (annual, timeseries) - Annual earnings: 1999 - 2025 - Sector breakdown: 2005 - 2025 - Reference period: April of each year - Published: October each year - Base: Employee jobs in Northern Ireland (not self-employed) Metrics: - weekly: Median gross weekly earnings (£) - hourly: Median hourly earnings excluding overtime (£) - annual: Median annual earnings (£) Dimensions: - timeseries: Historical trends by work pattern (Full-time/Part-time/All) - geography: Earnings by 11 Local Government Districts - sector: Public vs Private sector comparison (NI & UK) :returns: Timeseries: - year: Year - work_pattern: Full-time, Part-time, or All - median_*_earnings: Median earnings (£) - earnings_yoy_growth: YoY % change (if --growth specified) Geography: - year: Year - lgd: Local Government District name - basis: workplace or residence - median_weekly_earnings: Median weekly earnings (£) Sector: - year: Year - location: Northern Ireland or United Kingdom - sector: Public or Private - median_weekly_earnings: Median weekly earnings (£) :rtype: DataFrame with different columns depending on dimension .. note:: Source: NISRA Economic & Labour Market Statistics Branch https://www.nisra.gov.uk/statistics/work-pay-and-benefits/annual-survey-hours-and-earnings .. py:function:: nisra_composite_index_cmd(dimension, table_deprecated, year, quarter, output_format, force_refresh, save) NISRA Northern Ireland Composite Economic Index (NICEI) - Experimental Economic Indicator. Quarterly measure of NI economic performance tracking five key sectors: Services, Production, Construction, Agriculture, and Public Sector. Base period 2022=100, quarterly data from Q1 2006 to present. :param dimension: Which dimension to retrieve (indices, contributions, or all) :param table_deprecated: Deprecated alias for --dimension (use --dimension instead) :param year: Filter data for specific year :param quarter: Filter data for specific quarter (1-4) :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) .. rubric:: Examples Get latest NICEI indices:: bolster nisra composite-index Get sector contributions to quarterly change:: bolster nisra composite-index --dimension contributions Get all dimensions:: bolster nisra composite-index --dimension all Filter for specific year:: bolster nisra composite-index --year 2024 Get specific quarter:: bolster nisra composite-index --year 2025 --quarter 2 Save to file:: bolster nisra composite-index --save nicei.csv Data Notes: - Coverage: Q1 2006 - Q2 2025 (quarterly) - Base period: 2022 = 100 - Experimental statistic subject to revision - Published ~3 months after quarter end - Not seasonally adjusted Tables: indices: NICEI and component indices by quarter (Table 1) • Overall NICEI, private/public sector breakdowns • Sectoral indices: Services, Production, Construction, Agriculture • Quarterly time series from Q1 2006 contributions: Sector contributions to quarterly change (Table 11) • How much each sector contributed to NICEI quarterly change • Percentage point contributions • Identifies main drivers of economic growth/decline all: All available tables :returns: - date: Quarter start date - quarter: Quarter (Q1-Q4) - year: Year - Various index/contribution columns depending on table :rtype: DataFrame with columns varying by table type .. note:: Source: NISRA Economic & Labour Market Statistics Branch https://www.nisra.gov.uk/statistics/economic-output-statistics/ni-composite-economic-index .. py:function:: nisra_wellbeing_cmd(dimension, metric_deprecated, year, output_format, force_refresh, save) NISRA Individual Wellbeing Statistics. Retrieves individual wellbeing statistics for Northern Ireland, measuring subjective wellbeing across the population aged 16 and over. :param dimension: Which dimension to retrieve (personal, loneliness, self-efficacy, or summary) :param metric_deprecated: Deprecated alias for --dimension (use --dimension instead) :param year: Filter data for specific year (format: 2024/25) :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) Dimensions (personal, loneliness, self-efficacy, summary): personal - ONS4 measures (Life Satisfaction, Worthwhile, Happiness, Anxiety); scores 0-10 (higher is better, except Anxiety). loneliness - Proportion feeling lonely at least some of the time. self-efficacy - Mean self-efficacy scores (range 5-25). summary - Combined latest values for all measures. .. rubric:: Examples Get personal wellbeing (ONS4 measures):: bolster nisra wellbeing Get loneliness statistics:: bolster nisra wellbeing --dimension loneliness Get summary of all dimensions for latest year:: bolster nisra wellbeing --dimension summary Filter for a specific year:: bolster nisra wellbeing --year "2023/24" Save to file:: bolster nisra wellbeing --save wellbeing.csv Data Notes: - Personal wellbeing: Annual from 2014/15 to present - Loneliness: Annual from 2017/18 to present - Self-efficacy: Annual from 2014/15 to present - COVID-19 Note: 2020/21 shows increased anxiety and loneliness :returns: - year: Financial year (e.g., "2024/25") - life_satisfaction: Mean score 0-10 (higher is better) - worthwhile: Mean score 0-10 (higher is better) - happiness: Mean score 0-10 (higher is better) - anxiety: Mean score 0-10 (lower is better) :rtype: DataFrame with columns (for personal metric) .. note:: Source: https://www.nisra.gov.uk/statistics/wellbeing/individual-wellbeing-northern-ireland .. py:function:: nisra_cancer_cmd(target, dimension, year, output_format, force_refresh, save, summary) NISRA Cancer Waiting Times Statistics. Retrieves cancer waiting times performance data for Northern Ireland from the Department of Health, tracking progress against ministerial targets. Targets: 14-day (urgent breast referrals), 31-day (decision to treat), 62-day (urgent GP referral), referrals (monthly breast volumes). Dimensions: trust (HSC Trust breakdown) or tumour (tumour site breakdown). Examples:: bolster nisra cancer-waiting-times bolster nisra cancer-waiting-times --target 62-day --dimension tumour bolster nisra cancer-waiting-times --target 14-day bolster nisra cancer-waiting-times --year 2024 --summary bolster nisra cancer-waiting-times --save cancer.csv Key insights (as of 2025): 31-day target NI at ~90%; 62-day collapsed to ~32%; 14-day breast dropped from 77% (2020) to 17% (2025). Data from Q1 2008 to present. Source: https://www.health-ni.gov.uk/articles/cancer-waiting-times .. py:function:: nisra_emergency_care_cmd(output_format, trust, attendance_type, year, save, force_refresh) NISRA Emergency Care Waiting Times Statistics. Monthly A&E performance data for Northern Ireland measuring the 4-hour target (95% of attendances seen, treated, admitted or discharged within 4 hours). Data by hospital department and HSC Trust, April 2008 to present. Attendance Types: Type 1 - Major A&E departments (full A&E) Type 2 - Single specialty emergency departments Type 3 - Minor injury units and urgent treatment centres HSC Trusts: Belfast, Northern, South Eastern, Southern, Western Examples: --------- Get all data as CSV:: bolster nisra emergency-care Get Type 1 performance for Belfast Trust:: bolster nisra emergency-care --type 1 --trust Belfast Get 2024 data as JSON:: bolster nisra emergency-care --year 2024 --format json Save to file:: bolster nisra emergency-care --save emergency.csv Key Insights (as of 2026) ------------------------- - 4-hour target (95%): NI performance has declined significantly since 2008 - Type 1 performance well below target; Type 3 minor injury units perform best - Belfast RVH and Altnagelvin consistently the busiest Type 1 sites Source ------ https://www.health-ni.gov.uk/articles/emergency-care-waiting-times .. py:function:: nisra_elective_waiting_times_cmd(waiting_type, trust, year, output_format, force_refresh, save) NISRA Elective/Outpatient Waiting Times Statistics. \b Two quarterly series from the Department of Health NI: inpatient_day_case Patients waiting for inpatient/day case admission, by weeks-waited band, specialty, and HSC Trust. Data from Q1 2007-08 (June 2007) to present. outpatient Referrals waiting for an outpatient appointment, by weeks-waited band, specialty, and HSC Trust. Data from Q1 2008-09 (June 2008) to present. \b HSC Trusts: Belfast, Northern, South Eastern, Southern, Western \b Examples:: bolster nisra elective-waiting-times bolster nisra elective-waiting-times --type outpatient bolster nisra elective-waiting-times --trust Belfast --year 2024 bolster nisra elective-waiting-times --type inpatient_day_case --save inpatient.csv bolster nisra elective-waiting-times --format json \b Key insights (as of 2025): over 400,000 outpatient referrals waiting; median outpatient wait exceeding 43 weeks; inpatient waits exceeding 104 weeks visible across multiple specialties and trusts. \b Sources: https://www.health-ni.gov.uk/articles/inpatient-waiting-times https://www.health-ni.gov.uk/articles/outpatient-waiting-times .. py:function:: nisra_registrar_general_cmd(latest, quarterly, lgd, validate, dimension, table_deprecated, year, quarter, output_format, force_refresh, save) NISRA Registrar General Quarterly Tables. Quarterly vital statistics for Northern Ireland including births, deaths, marriages, civil partnerships, and LGD-level breakdowns. Data available from Q1 2009 to present. :param latest: Get the most recent quarterly tables data :param quarterly: Show full quarterly time series :param lgd: Show LGD (Local Government District) breakdown :param validate: Run cross-validation against monthly data :param dimension: Which dimension to retrieve (births, deaths, or all) :param table_deprecated: Deprecated alias for --dimension (use --dimension instead) :param year: Filter data for specific year :param quarter: Filter data for specific quarter (1-4) :param output_format: Output format (csv or json) :param force_refresh: Force re-download even if cached :param save: Save data to file (specify filename) Tables Available: births: Quarterly births, stillbirths, birth rates deaths: Quarterly deaths, marriages, civil partnerships, death rates lgd: Current quarter breakdown by Local Government District .. rubric:: Examples Get latest quarterly data (all tables):: bolster nisra registrar-general --latest Get quarterly births time series:: bolster nisra registrar-general --quarterly --dimension births Get LGD breakdown for current quarter:: bolster nisra registrar-general --lgd Cross-validate quarterly vs monthly data:: bolster nisra registrar-general --validate Get specific year/quarter:: bolster nisra registrar-general --quarterly --year 2024 --quarter 1 Save to file:: bolster nisra registrar-general --quarterly --save quarterly.csv Cross-Validation: The --validate option compares quarterly totals against aggregated monthly data from the births and marriages modules. Differences within 2% are considered acceptable (timing of registrations). Data Notes: - Quarterly data from Q1 2009 to present - Updated approximately 6 weeks after each quarter ends - 11 Local Government Districts in NI - Birth/death rates per 1,000 population :returns: - quarter: Quarter (Q1, Q2, Q3, Q4) - year: Year - Various statistical columns depending on table :rtype: DataFrame with columns varying by table type .. note:: Source: https://www.nisra.gov.uk/statistics/births-deaths-and-marriages/registrar-general-quarterly-report .. py:function:: psni() PSNI (Police Service of Northern Ireland) data sources. Access official statistics from the Police Service of Northern Ireland including: - Road Traffic Collision statistics (injury collisions, casualties, vehicles) - Police recorded crime statistics (from OpenDataNI) All data is sourced from OpenDataNI under the Open Government Licence v3.0. Geographic breakdowns use 11 Policing Districts aligned with LGDs. .. py:function:: psni_rtc_cmd(year, data_type, by, output_format, save, force_refresh) PSNI Road Traffic Collision Statistics. Retrieves police-recorded injury road traffic collision data including: - Collision records with date, location, road conditions - Casualty records with severity (fatal/serious/slight), road user type - Vehicle records with type and driver details :param year: Specific year to retrieve (default: latest) :param data_type: Type of data to retrieve (collisions, casualties, vehicles, or summary) :param by: Group results by dimension (district, road-user, or year) :param output_format: Output format (table, csv, or json) :param save: Save data to file (specify filename) :param force_refresh: Force re-download even if cached .. rubric:: Examples Get annual summary for all available years:: bolster psni rtc --data-type summary Get 2024 casualties by district:: bolster psni rtc --year 2024 --data-type casualties --by district Get casualties by road user type:: bolster psni rtc --data-type casualties --by road-user Export collision data to CSV:: bolster psni rtc --year 2024 --data-type collisions --format csv --save collisions.csv Data Notes: - Data covers injury collisions only (not damage-only) - Available from 2013 onwards via OpenDataNI - Severity: Fatal, Serious, Slight - Updated annually (~6 months after year end) :returns: DataFrame with various columns depending on data_type and grouping .. py:function:: psni_ombudsman_cmd(breakdown, output_format, save, force_refresh) Police Ombudsman Complaint Statistics. Retrieves official complaint statistics published by the Police Ombudsman for Northern Ireland, covering complaints, allegations, and case outcomes. Available breakdowns: \b totals - Total complaints 2000/01 to present by-district - Complaints by policing district, 2011/12+ by-allegation-type- Allegations by type and subtype, 2011/12+ by-outcome - Complaint closures by outcome, 2011/12+ quarterly - Quarterly complaints, latest 5 financial years Examples: \b bolster psni ombudsman bolster psni ombudsman --breakdown by-district bolster psni ombudsman --breakdown quarterly --format csv bolster psni ombudsman --breakdown by-allegation-type --save allegations.csv .. py:function:: psni_stop_search_cmd(year, district, output_format, save, force_refresh) PSNI Stop and Search Statistics (2017/18 onwards). Retrieves individual stop and search records for Northern Ireland covering: - Financial year and quarter - Legislation used (Misuse of Drugs Act, PACE, Justice & Security Act, etc.) - PACE-specific search reasons (stolen articles, prohibited articles, blade/point, fireworks) - Subject demographics (age group, gender) Note: This dataset does not include a policing district breakdown. All records are at Northern Ireland level only. .. rubric:: Examples Show summary table of all records:: bolster psni stop-search Filter to a specific financial year:: bolster psni stop-search --year 2023/24 Export all records to CSV:: bolster psni stop-search --format csv --save stop_search.csv Export 2024/25 data as JSON:: bolster psni stop-search --year 2024/25 --format json :returns: DataFrame with individual stop and search records. .. py:function:: psni_pace_cmd(breakdown, output_format, save, force_refresh) PSNI PACE (Police and Criminal Evidence Order) Statistics. Retrieves annual PACE statistics from PSNI Statistics Branch including: - Monthly stop and search counts by reason (stolen articles, offensive weapons, going equipped, fireworks) with associated arrests - Quarterly arrests under PACE by gender and legal-rights requests (solicitor, friend/relative) :param breakdown: Which table to retrieve ('stop-search' or 'arrests') :param output_format: Output format (table, csv, or json) :param save: Save data to file (specify filename) :param force_refresh: Force re-download even if cached .. rubric:: Examples Get monthly stop & search breakdown:: bolster psni pace --breakdown stop-search Get quarterly arrest demographics as CSV:: bolster psni pace --breakdown arrests --format csv Save arrests data to file:: bolster psni pace --breakdown arrests --save pace_arrests.csv Data Notes: - Single financial year per workbook; PACE_URLS updated each May - Stop & search reasons: Stolen Articles, Offensive Weapon/Blade or Point, Going Equipped/Prohibited Articles, Fireworks - Arrests breakdown: Total, Male, Female, Unknown/Other, Requested friend/relative, Requested solicitor .. py:function:: nisra_planning_statistics_cmd(dimension, financial_year, output_format, force_refresh, save, summary) NISRA Planning Activity Statistics (Department for Infrastructure). Quarterly Northern Ireland planning application statistics: applications received, decided, approved, withdrawn, and approval rate. NI-wide series goes back to Q1 2002/03; council-area breakdowns cover recent quarters across the 11 local councils. .. rubric:: Examples Quarterly NI-wide series (default):: bolster nisra planning-statistics Per-council quarterly data for the latest financial year:: bolster nisra planning-statistics --dimension council --financial-year 2024/25 Annual financial-year totals:: bolster nisra planning-statistics --dimension annual Council summary for 2024/25:: bolster nisra planning-statistics --dimension council-summary --financial-year 2024/25 Save to file:: bolster nisra planning-statistics --save planning.csv Source: https://www.infrastructure-ni.gov.uk/articles/planning-activity-statistics .. py:function:: nisra_baby_names_cmd(year, sex, top_n, output_format, force_refresh, save) NISRA Baby Names for Northern Ireland (1997 to present). \b Full historical list of all first forenames given to babies registered in Northern Ireland, with annual rank and count for every name by sex. .. rubric:: Examples Top 10 boys' names in 2024:: bolster nisra baby-names --year 2024 --sex Boys --top 10 All names for 2023 saved to file:: bolster nisra baby-names --year 2023 --save baby_names_2023.csv Full dataset as JSON:: bolster nisra baby-names --format json Source: https://www.nisra.gov.uk/statistics/births/baby-names .. py:function:: nisra_work_quality_cmd(indicator, year, output_format, force_refresh, save) NISRA Work Quality Statistics for Northern Ireland. \b Seventeen indicators of job quality for employees aged 18 and over, drawn from the Labour Force Survey (LFS) and Annual Survey of Hours and Earnings (ASHE). Covers 2020 to present with breakdowns by sex, age group, deprivation quintile, and skill level. .. rubric:: Examples All work quality indicators:: bolster nisra work-quality Filter to job satisfaction indicator:: bolster nisra work-quality --indicator job_satisfaction Data for 2023 saved as JSON:: bolster nisra work-quality --year 2023 --format json --save wq2023.json Source: https://www.nisra.gov.uk/statistics/labour-market-and-social-welfare/work-quality .. py:function:: nisra_public_confidence_cmd(breakdown, output_format, force_refresh, save) NISRA Public Confidence in Official Statistics (PCOS). \b Annual survey measuring public awareness of and trust in NISRA and official statistics, drawn from the Northern Ireland Continuous Household Survey (CHS). Data covers 2009–present for awareness and 2014–present for trust measures. Breakdowns: awareness Awareness of NISRA (2009–present) trust-nisra Trust in NISRA as an institution (2014–present) trust-civil-service Trust in the Civil Service (2014–present) trust-ni-assembly Trust in the NI Assembly/elected bodies (2014–present) trust-media Trust in the Media (2014–present) trust-nisra-statistics Trust in statistics produced by NISRA (2014–present) all-trust All five trust topics combined (adds topic column) .. rubric:: Examples Awareness of NISRA over time:: bolster nisra public-confidence Trust in NISRA statistics:: bolster nisra public-confidence --breakdown trust-nisra-statistics All trust topics as JSON:: bolster nisra public-confidence --breakdown all-trust --format json Save awareness data to CSV:: bolster nisra public-confidence --save awareness.csv Source: https://www.nisra.gov.uk/statistics/people-and-communities/public-awareness-and-trust-confidence-official-statistics-pcos .. py:function:: nisra_disease_prevalence_cmd(register, output_format, force_refresh, save, level, lcg) NI Raw Disease Prevalence Statistics (Department of Health). \b Annual disease register sizes and prevalence per 1,000 patients for Northern Ireland, covering 2004/05 to the most recently published year. Data originate from GP clinical disease registers (QOF). .. rubric:: Examples Full NI disease prevalence time series:: bolster nisra disease-prevalence Filter to hypertension register:: bolster nisra disease-prevalence --register hypertension GP-practice-level data for Belfast LCG:: bolster nisra disease-prevalence --level gp --lcg Belfast Export GP data as CSV:: bolster nisra disease-prevalence --level gp --format csv --save gp.csv Latest data as JSON:: bolster nisra disease-prevalence --format json Source: https://www.health-ni.gov.uk/articles/prevalence-statistics .. py:function:: nisra_qes_cmd(output_format, adjusted, year, force_refresh, save) NISRA Quarterly Employment Survey (QES). \b Employee jobs in Northern Ireland by sector (manufacturing, construction, services, other), Q1 1998 to present. Seasonally adjusted by default. .. rubric:: Examples All QES data (seasonally adjusted):: bolster nisra quarterly-employment-survey Unadjusted series saved as JSON:: bolster nisra quarterly-employment-survey --unadjusted --format json --save qes.json Filter to 2024:: bolster nisra quarterly-employment-survey --year 2024 Source: https://www.nisra.gov.uk/statistics/labour-market-and-social-welfare/quarterly-employment-survey .. py:function:: nisra_claimant_count_cmd(breakdown, output_format, force_refresh, save) NISRA Claimant Count statistics (UC + JSA). \b Monthly experimental statistics measuring the number of people claiming Universal Credit (UC) or Jobseeker's Allowance (JSA) principally for the reason of being unemployed. Data covers Northern Ireland with multiple geographic and demographic breakdowns. Breakdowns available: headline NI total by sex, seasonally adjusted + non-SA (from 1997) age NI total by age band: 16-24, 25-49, 50+ (from 2013) lgd 11 Local Government Districts (current month snapshot) pca 18 Parliamentary Constituency Areas (current month snapshot) ttwa 10 Travel-to-Work Areas (current month snapshot) .. rubric:: Examples Show latest headline claimant count in a table:: bolster nisra claimant-count Show age breakdown as CSV:: bolster nisra claimant-count --breakdown age --format csv Save LGD data to file:: bolster nisra claimant-count --breakdown lgd --save lgd.csv Export PCA data as JSON:: bolster nisra claimant-count --breakdown pca --format json --save pca.json Source: https://www.nisra.gov.uk/statistics/labour-market-and-social-welfare/claimant-count .. py:function:: psni_crime_cmd(output_format, save) PSNI historical crime statistics (Apr 2001–Dec 2021). \b ⚠️ This data source is STALE. The PSNI no longer publishes the structured OpenDataNI crime statistics dataset used by this module. The data covers April 2001 to December 2021 only and will not be updated. For more recent crime data, consult the PSNI's published statistical reports at https://www.psni.police.uk/statistics/ \b .. rubric:: Examples bolster psni crime --format csv --save crime_history.csv bolster psni crime --format json .. py:function:: education() Education statistics for Northern Ireland. Access official education data from the Department of Education Northern Ireland (DE NI), including pupil suspension and expulsion statistics. .. py:function:: education_suspensions_cmd(year, output_format, force_refresh, save, summary) NI Pupil Suspensions and Expulsions (Department of Education). \b Annual suspension statistics for pupils of compulsory school age in Northern Ireland, covering 2011/12 to present. .. rubric:: Examples Full suspension time series:: bolster education suspensions Filter to a single academic year:: bolster education suspensions --year 2023/24 Summary overview:: bolster education suspensions --summary Save as CSV:: bolster education suspensions --save suspensions.csv Source: https://www.education-ni.gov.uk/articles/pupil-suspensions-and-expulsions .. py:function:: list_sources() List all available data sources and their descriptions. Shows a comprehensive overview of all data sources available in the Bolster library, organized by category with brief descriptions of what data each source provides.