Example usage
To use fivpy in a project:
import fivpy
print('fivpy version:', fivpy.__version__)
fivpy version: 0.1.0
Examples
Calculating a forest inventory using Simple Random Sampling:
import pandas as pd
from fivpy import RandomSampling
# Loading the data
data = pd.read_csv('../src/fivpy/data/data_2.csv', sep=';', decimal=',')
inventory_1 = RandomSampling(data,
unit_area=0.02,
sampling_area=11,
significance=90,
sampling_error=10)
inventory_1.srs_inventory()
WARNING - Adding columns with DBH and Volume.
WARNING - Degrees of freedom not informed.Using default value: 4
INFO - Calculating final inventory.
| Variables | Data | |
|---|---|---|
| 0 | Ym | 1.580323 |
| 1 | StdDev | 0.163009 |
| 2 | CV | 10.314946 |
| 3 | S² | 0.026572 |
| 4 | N samples | 4.000000 |
| 5 | N Total | 550.000000 |
| 6 | MeanErr | 0.072568 |
| 7 | Total V | 869.177473 |
| 8 | Err | 0.154704 |
| 9 | E(%) | 9.789372 |
| 10 | CI Supe | 1.735026 |
| 11 | CI Infe | 1.425619 |
| 12 | Ym/ha | 79.016134 |
| 13 | CI Supe ha | 86.751317 |
| 14 | CI Infe ha | 71.280950 |
| 15 | Ym/total | 869.177473 |
| 16 | CI Supe total | 954.264491 |
| 17 | CI Infe total | 784.090455 |
| 18 | MRE | 1.469061 |
| 19 | MRE Pop | 807.983606 |