gEconpy.model.perturbation.make_not_loglin_flags#
- gEconpy.model.perturbation.make_not_loglin_flags(variables, calibrated_params, steady_state, log_linearize=True, not_loglin_variables=None, loglin_negative_ss=False, verbose=True)#
Determine which variables should not be log-linearized.
Returns a flag array where
1means “do not log-linearize” and0means “log-linearize.” Variables are excluded from log-linearization if they are explicitly listed innot_loglin_variables, have steady-state values near zero, or (unlessloglin_negative_ssis True) have negative steady-state values.- Parameters:
- variables
listofTimeAwareSymbol Model variables.
- calibrated_params
listofsp.Symbol Calibrated parameters that also appear in the steady-state vector.
- steady_state
SymbolDictionary Steady-state values, keyed by variable name.
- log_linearizebool, default
True If False, returns all-ones (no variable is log-linearized).
- not_loglin_variables
listofstr, optional Variable names the user explicitly excludes from log-linearization.
- loglin_negative_ssbool, default
False If True, variables with negative steady-state values are still log-linearized.
- verbosebool, default
True Log warnings about excluded variables.
- variables
- Returns:
- flags
np.ndarray Array of length
len(variables) + len(calibrated_params). Entry is1if the variable should not be log-linearized,0otherwise.
- flags