FrequencySeriesList

Stability: Stable

What it is

Use FrequencySeriesList to manage multiple FrequencySeries objects as a labeled collection with batch operations and conversion helpers.

Representative Signatures

FrequencySeriesList(data: list[FrequencySeries])
FrequencySeriesList.to_matrix()

Minimal Example

from gwexpy.frequencyseries import FrequencySeries, FrequencySeriesList
import numpy as np

lst = FrequencySeriesList([FrequencySeries(np.ones(64), df=1.0)])
mat = lst.to_matrix()

API Reference

The detailed generated API continues below on this page.

Inherits from: FrequencySeriesBaseList

List of FrequencySeries objects.

Physical Context

Use FrequencySeriesList when you have several spectra that should keep their per-series identity: repeated measurements, different sensors, or several processing branches of the same channel.

  • each entry can still carry its own metadata and channel name

  • batch methods are convenient, but the list does not guarantee identical units, df, or calibration state

Common Misreadings

  1. assuming every entry is frequency-aligned just because they live in one list

  2. overlaying spectra with different normalization or units and reading the result physically

  3. treating list order as provenance unless you set names or labels deliberately

Where to go next

Methods

__init__

__init__(self, *items: 'Union[_FS, Iterable[_FS]]')

Initialize self. See help(type(self)) for accurate signature.

(Inherited from list)

EntryClass

EntryClass(data, unit=None, f0=None, df=None, frequencies=None, name=None, epoch=None, channel=None, **kwargs)

Light wrapper of gwpy’s FrequencySeries for compatibility and future extension.

angle

angle(self, *args, **kwargs) -> "'FrequencySeriesList'"

Alias for phase(). Returns a new FrequencySeriesList.

append

append(self, item: '_FS')

Append object to the end of the list.

(Inherited from list)

apply_response

apply_response(self, *args, **kwargs) -> "'FrequencySeriesList'"

Apply response to each FrequencySeries in the list. Returns a new FrequencySeriesList.

copy

copy(self) -> "'FrequencySeriesBaseList[_FS]'"

Return a shallow copy of the list.

(Inherited from list)

crop

crop(self, *args, **kwargs) -> "'FrequencySeriesList'"

Crop each FrequencySeries in the list. Returns a new FrequencySeriesList.

degree

degree(self, *args, **kwargs) -> "'FrequencySeriesList'"

Compute phase (in degrees) of each FrequencySeries. Returns a new FrequencySeriesList.

differentiate_time

differentiate_time(self, *args, **kwargs) -> "'FrequencySeriesList'"

Apply time differentiation to each item. Returns a new FrequencySeriesList.

extend

extend(self, items: 'Iterable[_FS]') -> 'None'

Extend list by appending elements from the iterable.

(Inherited from list)

filter

filter(self, *args, **kwargs) -> "'FrequencySeriesList'"

Apply filter to each FrequencySeries in the list. Returns a new FrequencySeriesList.

group_delay

group_delay(self, *args, **kwargs) -> "'FrequencySeriesList'"

Compute group delay of each item. Returns a new FrequencySeriesList.

ifft

ifft(self, *args, **kwargs)

Compute IFFT of each FrequencySeries. Returns a TimeSeriesList.

insert

insert(self, index: 'int', item: '_FS') -> 'None'

Insert object before index.

(Inherited from list)

integrate_time

integrate_time(self, *args, **kwargs) -> "'FrequencySeriesList'"

Apply time integration to each item. Returns a new FrequencySeriesList.

interpolate

interpolate(self, *args, **kwargs) -> "'FrequencySeriesList'"

Interpolate each FrequencySeries in the list. Returns a new FrequencySeriesList.

pad

pad(self, *args, **kwargs) -> "'FrequencySeriesList'"

Pad each FrequencySeries in the list. Returns a new FrequencySeriesList.

phase

phase(self, *args, **kwargs) -> "'FrequencySeriesList'"

Compute phase of each FrequencySeries. Returns a new FrequencySeriesList.

plot

plot(self, **kwargs: 'Any')

Plot all series. Delegates to gwexpy.plot.Plot.

plot_all

plot_all(self, *args: 'Any', **kwargs: 'Any')

Alias for plot(). Plots all series.

read

read(source, *args, **kwargs)

No documentation available.

segments

Frequency spans of each element (xspan).

smooth

smooth(self, *args, **kwargs) -> "'FrequencySeriesList'"

Smooth each FrequencySeries. Returns a new FrequencySeriesList.

to_control_frd

to_control_frd(self, *args, **kwargs) -> 'list'

Convert each item to control.FRD. Returns a list of FRD objects.

to_cupy

to_cupy(self, *args, **kwargs) -> 'list'

Convert each item to cupy.ndarray. Returns a list of Arrays.

to_db

to_db(self, *args, **kwargs) -> "'FrequencySeriesList'"

Convert each FrequencySeries to dB. Returns a new FrequencySeriesList.

to_jax

to_jax(self, *args, **kwargs) -> 'list'

Convert each item to jax.Array. Returns a list of Arrays.

to_pandas

to_pandas(self, **kwargs)

Convert to pandas.DataFrame. Columns are named by channel name or index.

to_tensorflow

to_tensorflow(self, *args, **kwargs) -> 'list'

Convert each item to tensorflow.Tensor. Returns a list of Tensors.

to_tmultigraph

to_tmultigraph(self, name: 'Optional[str]' = None) -> 'Any'

Convert to ROOT TMultiGraph.

to_torch

to_torch(self, *args, **kwargs) -> 'list'

Convert each item to torch.Tensor. Returns a list of Tensors.

to_xarray

to_xarray(self)

Convert to xarray.DataArray. Concatenates along a new dimension β€˜channel’.

write

write(self, target: 'str', *args: 'Any', **kwargs: 'Any') -> 'Any'

Write list to file (HDF5, ROOT, etc.).

For HDF5 output you can choose a layout (default is GWpy-compatible dataset-per-entry).

fsl.write("out.h5", format="hdf5")               # GWpy-compatible (default)
fsl.write("out.h5", format="hdf5", layout="group")  # legacy group-per-entry

Warning

Never unpickle data from untrusted sources. pickle/shelve can execute arbitrary code on load.

Pickle portability note: pickled gwexpy FrequencySeriesList unpickles as a built-in list of GWpy FrequencySeries (gwexpy not required on the loading side).

zpk

zpk(self, *args, **kwargs) -> "'FrequencySeriesList'"

Apply ZPK filter to each FrequencySeries in the list. Returns a new FrequencySeriesList.