Class DemographicData

java.lang.Object
org.episteme.social.sociology.DemographicData
All Implemented Interfaces:
Serializable, UniversalDataModel

public final class DemographicData extends Object implements UniversalDataModel, Serializable
Data model for demographic population structures. Supports representation via individual age-SociologicalGroup cohorts or aggregation from social groups. Provides consolidated segments for population pyramid visualizations.
Since:
1.0
Version:
1.1
Author:
Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
See Also:
  • Constructor Details

    • DemographicData

      public DemographicData()
  • Method Details

    • getModelType

      public String getModelType()
      Description copied from interface: UniversalDataModel
      Returns a unique identifier for the type of data model. Examples: "SPATIAL_GEOMETRY", "ECONOMIC_PORTFOLIO", "ARCHITECTURAL_PLAN".
      Specified by:
      getModelType in interface UniversalDataModel
    • addGroup

      public void addGroup(int min, int max, long male, long female)
      Manually adds an age cohort to the model.
      Parameters:
      min - minimum age in years
      max - maximum age in years
      male - number of males
      female - number of females
    • addGroup

      public void addGroup(SociologicalGroup SociologicalGroup)
      Adds a social SociologicalGroup to the model for automated aggregation.
      Parameters:
      SociologicalGroup - the SociologicalGroup to add
    • getPopulationName

      public String getPopulationName()
      Returns the name of the population being modeled.
      Returns:
      the name
    • setPopulationName

      public void setPopulationName(String name)
      Sets the name of the population.
      Parameters:
      name - the name to set
    • getConsolidatedGroups

      public List<DemographicData.AgeGroup> getConsolidatedGroups(int bucketSize)
      Consolidates all data into a list of AgeGroup segments for visualization.
      Parameters:
      bucketSize - the cohort size in years (e.g., 5 for 5-year chunks)
      Returns:
      a sorted list of age cohorts
    • getTotalPopulation

      public long getTotalPopulation()
      Returns the total population count across all specified segments and groups.
      Returns:
      total count
    • getQuantities

      public Map<String, Quantity<?>> getQuantities()
      Description copied from interface: UniversalDataModel
      Returns the primary physical values associated with this model. This allows generic tools to extract and convert measurements.
      Specified by:
      getQuantities in interface UniversalDataModel