momepy.floor_area¶
-
momepy.floor_area(area, height, floor_height=
3)[source]¶ Calculates floor area of each object based on height and area.
The number of floors is simplified into the formula:
height // floor_height. B y default one floor is approximated to 3 metres.\[area * \frac{height}{floor_height}\]- Parameters:¶
- Returns:¶
array of a type depending on the input
- Return type:¶
NDArray[np.float64] | Series
Examples
>>> import pandas as pd >>> area = pd.Series([100, 30, 40, 75, 230]) >>> height = pd.Series([22, 6.5, 12, 9, 4.5]) >>> momepy.floor_area(area, height) 0 700.0 1 60.0 2 160.0 3 225.0 4 230.0 dtype: float64If you know average height of floors per each building, you can pass it directly:
>>> floor_height = pd.Series([3.2, 3, 4, 3, 4.5]) >>> momepy.floor_area(area, height, floor_height=floor_height) 0 600.0 1 60.0 2 120.0 3 225.0 4 230.0 dtype: float64