Metadata-Version: 2.4
Name: strategicc
Version: 2.2.0
Summary: State and Transition Integrated Economic-Environmental Accounting
Author: Shlhnj
License: MIT License
        
        Copyright (c) 2026 Shlhnj
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Project-URL: Homepage, https://github.com/Shlhnj/strategicc
Project-URL: Repository, https://github.com/Shlhnj/strategicc
Project-URL: Issues, https://github.com/Shlhnj/strategicc/issues
Keywords: STSM,land cover,ecosystem accounting,SEEA-EA,landscape ecology,Monte Carlo
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Topic :: Scientific/Engineering :: GIS
Classifier: Intended Audience :: Science/Research
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy>=1.24
Requires-Dist: pandas>=2.0
Requires-Dist: Pillow>=10.0
Requires-Dist: matplotlib>=3.7
Provides-Extra: dev
Requires-Dist: pytest>=7.0; extra == "dev"
Requires-Dist: pytest-cov; extra == "dev"
Dynamic: license-file

# strategicc
STRATEGICC: State and Transition Integrated Economic-Environmental Accounting

A python package implementation of State-and-Transition Simulation Model (STSM) framework laid by Daniel et al (2016) (https://doi.org/10.1111/2041-210X.12597), integrated with the System of Economic-Environmental Accounting - Ecosystem Accounting (SEEA-EA) by United Nations (https://seea.un.org/ecosystem-accounting).

## Usage
### install the package
```
!pip install git+https://github.com/Shlhnj/strategicc.git
```


### Set Configuration

```
import strategicc.config as cfg
from pathlib import Path

cfg.LULC_PATH          = Path("2022.tif")
cfg.STATE_CLASSES_CSV  = Path("25062026 State Class.csv")
cfg.TRANSITIONS_CSV    = Path("23062026_stsm_transition_probabilities.csv")
cfg.SPATIAL_MULT_CSV   = Path("27062026 Transition Spatial Multipliers.csv")
cfg.TRANSITION_MULT_CSV= Path("27062026 Transition Multipliers.csv")
cfg.MULT_DIR           = Path("mult_spat/")   #folder for transition spatial multiplier
cfg.OUT_DIR            = Path("strategicc_test") #output folder


cfg.ADJACENCY_STRENGTH   = 2
cfg.START_YEAR           = 2022
cfg.N_TIMESTEPS          = 30
cfg.N_ITERATIONS         = 100    
cfg.RNG_SEED             = 42

cfg.USE_ADJACENCY        = True
cfg.USE_SPATIAL_MULT     = True
cfg.USE_TRANS_MULTIPLIER = True
```

### Diagnose Configuration

```
from strategicc import STSMEngine

engine = STSMEngine.from_config()
engine.load()
engine.diagnostic()
```

### Run Engine

```
engine.run()
```

### Show Summary Plot

```
from strategicc import outputs

summary_dir = engine.out_dir / "summary"

print("Building summary tables...")
area_df, trans_df = outputs.build_summary_tables(engine.iter_dirs, summary_dir)

print("Plotting area envelope...")
outputs.plot_area_envelope(area_df, engine.classes, summary_dir)

print("Plotting transition envelope...")
outputs.plot_transition_envelope(trans_df, summary_dir)

Show plots inline
from IPython.display import Image, display
display(Image(str(summary_dir / "area_envelope.png")))
display(Image(str(summary_dir / "transition_envelope.png")))
```
