swectral.vegeind.create_specind_demo_data#

swectral.vegeind.create_specind_demo_data(nsample=20, nband=462, wavelength_range=(387.6, 1005.6), *, seed=None)[source]#

Generate demostration 2D spectral data array with column names as wavelengths.

The function is for test and demonstration purpose of spectral index functions.

Parameters:
nsampleint, optional

Number of samples. The default is 20.

nbandint, optional

Number of bands. The default is 462.

wavelength_range: tuple of (int or float, int or float)

Range of wavelength.

seedint or None, optional

Seed for random data. The default is None.

Returns:
pandas.DataFrame

Exemplary spectral data table with wavelengths for spectral index computation.

Return type:

DataFrame

Examples

Use default settings:

>>> df_spec = create_vegeind_demo_data()

Customize sample number, number of bands and wavelength range:

>>> df_spec = create_vegeind_demo_data(20, 1000, (50, 15000))