fivpy
Subpackages
Submodules
Package Contents
Classes
Class to create a forest inventory object |
Functions
|
Loads the data from the board 4.1. - Credits to Soares, Paula Neto & Souza |
|
Loads one of the bult-in datasets with data collected in the Atlantic |
|
Loads one of the bult-in datasets with data collected in the Atlantic |
Attributes
- fivpy.__version__
- class fivpy.RandomSampling(dataframe, unit_area, sampling_area, significance=95, sampling_error=20, deg_free=None)[source]
Class to create a forest inventory object which uses Simple Random Sampling to estimate total wood volume
- get_vol(self, beta_0=7.4e-05, beta_1=1.707348, beta_2=1.16873)[source]
Add a column with volume info to the dataframe
- Parameters
beta_0 (float, optional) – first parameter. Defaults to 0.000074.
beta_1 (float, optional) – second parameter. Defaults to 1.707348.
beta_2 (float, optional) – third parameter. Defaults to 1.16873.
- Returns
A DataFrame containing volume info.
- Return type
dataframe (pd.DataFrame)
Examples
>>> instance.get_vol() ### To change the equation used to calculate volume >>> instance.get_vol(beta_0=0.000025, beta_1=1.4568, beta_2=1.2563)
- get_sample_size(self)[source]
Returns the estimated required sample size to perform the definitive inventory
- Returns
the required sample size
- Return type
sample size (int)
Examples
>>> instance.get_sample_size()
- srs_inventory(self)[source]
Performs the Simple Random Sampling inventory
- Raises
ValueError – If the required sample size is greater than the number
of units sampled, it is not possible to perform the inventory. –
- Returns
A DataFrame containing the inventory results.
- Return type
dataframe (pd.DataFrame)
Examples
>>> instance.srs_inventory()
- fivpy.data_1()[source]
Loads the data from the board 4.1. - Credits to Soares, Paula Neto & Souza (2010). The board contains the columns:
units: the sample units used columns: the columns selected from the complete data rows: the rows selected from the complete data volume: the volume of the sample unit
- Returns
The data.
- Return type
data (pandas.DataFrame)
Examples
>>> data_1()
- fivpy.data_2()[source]
Loads one of the bult-in datasets with data collected in the Atlantic Forest, Bahia, Brazil. The dataset contains the columns:
n_tree: number of the tree on field units: the sample units used cbh: circumference at breast height height: height of the tree
- Returns
The data.
- Return type
data (pandas.DataFrame)
Examples
>>> data_2()
- fivpy.data_3()[source]
Loads one of the bult-in datasets with data collected in the Atlantic Forest, Bahia, Brazil. The dataset contains the columns:
n_tree: number of the tree on field units: the sample units used cbh: circumference at breast height height: height of the tree
- Returns
The data.
- Return type
data (pandas.DataFrame)
Examples
>>> data_3()