Skip to main content

A package performing power spectrum analysis, and comparing the given signal with red noise

Project description

class RedNoiseAnalysis(
    signal,
    lag = 1,
    chunk_size = 1825,
    n_red_noise_ens = 1000,
    red_noise_simulate_length = 365000
)

This is a package that performing temporal power spectrum analysis, and comparing given signal with theoretical red noise and simulated red noise.

Usage

Calculating power spectrum of given signal, and red noise which has similar memory with given signal.

from pyRedNoise.RedNoiseAnalysis import RedNoiseAnalysis
signal = np.load("signal.npy")

rna = RedNoiseAnalysis(signal)
rna.get_power_spectrum()

# Given signal
rna.signal

# power spectrum of given signal
rna.sp

# frequencies of given signal
rna.freq

# theoretical red noise power spectrum
rna.sp_theo

# theoretical red noise frequencies
rna.freq_theo

# simulated red noise power spectrum
rna.sp_red

# simulated red noise frequencies
rna.freq_red

Fast visualization. If you have specific plotting needs, calling this method is not suggested.

rna.plot_power_spectrum() # show and save the plot at the same time

Notes

Details of derivation, theory, and implementation can be found in https://github.com/Prcpltwfkwd-TW/Power_Spectrum_Analysis.git

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyrednoise-0.0.2.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyrednoise-0.0.2-py3-none-any.whl (6.5 kB view details)

Uploaded Python 3

File details

Details for the file pyrednoise-0.0.2.tar.gz.

File metadata

  • Download URL: pyrednoise-0.0.2.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.0

File hashes

Hashes for pyrednoise-0.0.2.tar.gz
Algorithm Hash digest
SHA256 deb817fe6c12049af23703a14e5a78858a45b59518a83df3f52f0646812ed952
MD5 86c43b371360bd83ed7247563828c30e
BLAKE2b-256 ff407cab87a61519b241e52889b1de894a429b3dfd0f6298ea08d83f3824d0d9

See more details on using hashes here.

File details

Details for the file pyrednoise-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: pyrednoise-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 6.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.0

File hashes

Hashes for pyrednoise-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b513b380a726288afa738d8585e008f1be67ace31e6806f80744b72ef132c337
MD5 95b273767e621588ab096c62c3669b8b
BLAKE2b-256 8996d86482704816e465ca6e7330c76a523c077f9977f0743d4a5273f81a576c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page