Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2024 spreadsheet updates #6

Merged
merged 18 commits into from
Feb 21, 2024
Merged

2024 spreadsheet updates #6

merged 18 commits into from
Feb 21, 2024

Conversation

brtietz
Copy link
Collaborator

@brtietz brtietz commented Feb 20, 2024

Changes:

  • New tech details for Natural Gas, Pumped Storage Hydropower
  • Advanced scenario for Nuclear
  • CFF by tech detail for Nuclear
  • Nuclear base year is 2030
  • New ITC/PTC structure for PV+Battery, including automatically changing the structure

@brtietz brtietz changed the base branch from main to dev February 20, 2024 20:28
@@ -230,7 +231,7 @@ def calculate_all_debt_fractions(data_workbook_filename: str, output_filename: s
OUTPUT_FILENAME - File to save calculated debt fractions to. Should end with .csv
"""
tech_map: Dict[str, Type[TechProcessor]] = {tech.__name__: tech for tech in LCOE_TECHS}
techs = LCOE_TECHS if tech is None else [tech_map[tech]]
techs = [lcoe_calculator.tech_processors.UtilityPvPlusBatteryProc]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this correct?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is not. Looks like I forgot to update this file after getting things working in lcoe calculator. I'll convert the PR to draft.

@@ -99,7 +99,7 @@ def tech_name(self) -> str:
dscr: float|None = None # Debt service coverage ratio (unitless, typically 1-1.5)

def __init__(self, data_workbook_fname: str, case: str = MARKET_FIN_CASE,
crp: CrpChoiceType = 30, extractor: Type[AbstractExtractor] = Extractor):
crp: CrpChoiceType = 30, tcc : str = None, extractor: Type[AbstractExtractor] = Extractor):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be tcc: Optional[str] = None

@brtietz brtietz marked this pull request as draft February 20, 2024 20:45
itc = self._calc_itc()

# Trim the first year to eliminate pre-inflation reduction act confusion
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this "trim first year" or is it more of "trim year 20XX"? Will this still be valid next year?

@@ -30,14 +30,16 @@ class Extractor(AbstractExtractor):
tax_credits_sheet = 'Tax Credits'

def __init__(self, data_workbook_fname: str, sheet_name: str, case: str, crp: CrpChoiceType,
scenarios: List[str], base_year: int):
scenarios: List[str], base_year: int, tax_credit_case : str = None):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is starting to stretch my OOP knowledge, but if tax_credit_case is only used in the child class, I think it can (and should) be left out of the parent constructor. Does that sound right? Also use Optional[str] for the tcc type.

"""
@param data_workbook_fname - IGNORED
@param sheet_name - IGNORED
@param case - 'Market' or 'R&D'
@param crp - capital recovery period: 20, 30, or 'TechLife'
@param scenarios - IGNORED
@param base_year - IGNORED
@param tax_credit_case - IGNORED, only used by PV+Battery
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❤️

@brtietz brtietz marked this pull request as ready for review February 21, 2024 19:56
Copy link
Collaborator

@mikebannis mikebannis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@brtietz brtietz merged commit 5f91489 into dev Feb 21, 2024
@brtietz brtietz deleted the 2024_spreadsheet_updates branch February 21, 2024 23:02
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.

2 participants