FireGenerator: Generate random sequence of fire events#
- class FireGenerator(*args, **kwds)[source]#
Bases:
Component
Generate a random fire event or time series.
- Parameters:
mean_fire_recurrence (float) – Average time between fires for a given location
shape_parameter (float) – Describes the skew of the Weibull distribution. If shape < 3.5, data skews left. If shape == 3.5, data is normal. If shape > 3.5, data skews right. To approximate a normal bell curve, use a value of 3.5
scale_parameter (float, optional) – Describes the peak of the Weibull distribution, located at the 63.5% value of the cumulative distribution function. If unknown, it can be found using mean fire recurrence value and the get_scale_parameter() method described later.
Generate a random fire event in time.
- Parameters:
grid (landlab model grid) –
mean_fire_recurrence (float) – Average time between fires for a given location
shape_parameter (float) – Describes the skew of the Weibull distribution. If shape < 3.5, data skews left. If shape == 3.5, data is normal. If shape > 3.5, data skews right.
scale_parameter (float, optional) – Describes the peak of the Weibull distribution, located at the 63.5% value of the cumulative distribution function. If unknown, it can be found using mean fire recurrence value and the get_scale_parameter().
- __init__(grid, mean_fire_recurrence=1.0, shape_parameter=3.5, scale_parameter=None)[source]#
Generate a random fire event in time.
- Parameters:
grid (landlab model grid) –
mean_fire_recurrence (float) – Average time between fires for a given location
shape_parameter (float) – Describes the skew of the Weibull distribution. If shape < 3.5, data skews left. If shape == 3.5, data is normal. If shape > 3.5, data skews right.
scale_parameter (float, optional) – Describes the peak of the Weibull distribution, located at the 63.5% value of the cumulative distribution function. If unknown, it can be found using mean fire recurrence value and the get_scale_parameter().
- generate_fire_recurrence()[source]#
Get time to next fire.
Finds the time to next fire (fire recurrence) based on the scale parameter (63.5% of fire Weibull distribution) and the shape parameter (describes the skew of the histogram, shape = 3.5 represents a normal distribution).
Rounds the time to next fire to 4 significant figures, for neatness.
- Returns:
Updated value for the time to next fire.
- Return type:
- get_scale_parameter()[source]#
Get the scale parameter.
- ::
- mean_fire_recurrence = (scale_parameter * (
special.gamma(1 + (1 / shape))))
sets the scale parameter.
- property scale_parameter#
Scale parameter for the random distribution.