momepy.volume#
- momepy.volume(area, height)[source]#
Calculates volume of each object in given GeoDataFrame based on its height and area.
\[area * height\]- Parameters:
- areaNDArray[np.float64] | Series
array of areas
- heightNDArray[np.float64] | Series
array of heights
- Returns:
- NDArray[np.float64] | Series
array of a type depending on the input
Examples
>>> import pandas as pd >>> area = pd.Series([100, 30, 40, 75, 230]) >>> height = pd.Series([22, 6.5, 12, 9, 4.5]) >>> momepy.volume(area, height) 0 2200.0 1 195.0 2 480.0 3 675.0 4 1035.0 dtype: float64