Skip to content

New fuelCovariates option: dom/sec/other AGB + treedWetland_agb - #48

Merged
eliotmcintire merged 6 commits into
developmentfrom
feat/domSecOther-fuels
Sep 28, 2026
Merged

eliotmcintire merged 6 commits into
developmentfrom
feat/domSecOther-fuels

Conversation

@eliotmcintire

Copy link
Copy Markdown
Collaborator

prepare_SpreadFit() (fireSense_dataPrepFit.R ~690) called fireSenseUtils::fireSenseCovariatesCreate() without rstLCC, so the treedWetland indicator never appeared, and there was no way to use the new dom/sec/other AGB fuel representation added in PredictiveEcology/fireSenseUtils#98. A new parameter, fuelCovariates (default "domSecOther"), now passes rstLCC and builds four AGB columns per ELF (dom_agb_, sec_agb_, other_agb, treedWetland_agb) instead of one column per fuel class. The dominant/secondary classes are chosen once per ELF, from the most recent data year, by the new fireSenseUtils::chooseDomSecFuelClasses(), stored in sim$fuelClassRoles so every data year's covariates use the same two classes; that function is added to the prepSpreadFitData cache key alongside PR #47's list. fuelCovariates = "species" keeps the previous behaviour unchanged.

Verified with SpaDES.core::convertToPackage() + testthat::test_local(), against a fireSenseUtils build combining this branch's floor (0.2.3.9053) with #97's harmonizeFireDataDeps(): 169 tests pass on this PR's base (fix/harmonize-cache-inner-fns), 181 pass on this branch, 0 failures either way; the 12 new expectations in test-domSecOtherFuels.R fail on the base (missing parameter/function) and pass here. Rmd/md/html re-rendered for the new parameter and output. Version bumped to 1.2.0.9016, floors fireSenseUtils@development (>= 0.2.3.9053).

Merge order: PredictiveEcology/fireSenseUtils#98 (stacked on #93, now based on development) and #97 before this; this PR after #47.

🤖 Generated with Claude Code

https://claude.ai/code/session_01CwcjqqK59FmTJscyi7xUqv

eliotmcintire and others added 4 commits September 28, 2026 11:39
prepare_SpreadFit() (fireSense_dataPrepFit.R ~690) built the spread covariate
table with fireSenseUtils::fireSenseCovariatesCreate() but never passed
rstLCC, so treedWetland never appeared, and there was no way to ask for the
new dom/sec/other AGB fuel representation added in fireSenseUtils#98.

New parameter fuelCovariates (default "domSecOther") passes rstLCC and picks
the representation. The dominant/secondary fuel classes are chosen once per
ELF, from the most recent data year, via the new
fireSenseUtils::chooseDomSecFuelClasses(), and recorded in sim$fuelClassRoles
so every data year's covariates use the same two classes.
chooseDomSecFuelClasses() is added to the prepSpreadFitData cache key
(.useCacheArgs), matching PR #47. fuelCovariates = "species" keeps the
previous one-column-per-fuel-class behaviour.

Version 1.2.0.9016. Floors fireSenseUtils@development (>= 0.2.3.9053).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CwcjqqK59FmTJscyi7xUqv
…ter development moved)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CwcjqqK59FmTJscyi7xUqv
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CwcjqqK59FmTJscyi7xUqv
@eliotmcintire eliotmcintire reopened this Sep 28, 2026
Base automatically changed from fix/harmonize-cache-inner-fns to development September 28, 2026 19:33
@eliotmcintire eliotmcintire reopened this Sep 28, 2026
eliotmcintire and others added 2 commits September 28, 2026 12:55
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CwcjqqK59FmTJscyi7xUqv
…er-fuels

# Conflicts:
#	fireSense_dataPrepFit.html
#	fireSense_dataPrepFit.md
@eliotmcintire
eliotmcintire merged commit 68adbcc into development Sep 28, 2026
6 checks passed
@eliotmcintire
eliotmcintire deleted the feat/domSecOther-fuels branch September 28, 2026 20:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant