[SciPy-User] Signal to noise ratio
Wed Feb 24 09:47:00 CST 2010
Just to add, while one can define the "statistical SNR" as something else
(that is, ratio E[s]/sigma_noise), what would be its used for? Astronomical
On the other hand, it doesn't really matter how it is defined in
scipy.stats. Calculation of SNR is usually a bit more involved (you need to
find the actual signal mean, and the noise variance), and I guess whoever
needs to calculate the power based SNR will not call that function by
On 24 February 2010 10:23, <email@example.com> wrote:
> On Wed, Feb 24, 2010 at 10:16 AM, Ivo Maljevic <firstname.lastname@example.org>
> > One would think that you can always rely on wikipedia when it comes to
> > and engineering, but it seems that is not tha case.
> > Josef, In the page you referenced, the SNR, or signal to noise ratio, is
> > defined as the ratio between the signal and noise powers. Consequently,
> > terms of signals and standard deviations, it is defined as a ratio of the
> > average signal power and the noise variance (NOT its squre root, or
> > deviation). Or:
> > SNR = P_s / sigma^2
> > where P_s is the average signal power, and the noise variance is used to
> > measure the noise power. The assumption here is that the noise is a zero
> > mean process, otherwise variance and power wouldn't be the same thing.
> Note: I linked to #Statistical_definition not the top of the wikipedia page
> and I checked the source in scipy.stats:
> Calculates the signal-to-noise ratio, defined as the ratio between the
> and the standard deviation.
> m = np.mean(a, axis)
> sd = samplestd(a, axis)
> return np.where(sd == 0, 0, m/sd)
> I didn't know about the different definitions until I read the
> Wikipedia page, but that's what's currently in scipy.stats
> > Nils, your question is way too generic for anyone to help you directly. I
> > can only point to you that your signal to noise ratio is quite low:
> >>>> 10*math.log10(0.0447)
> > -13.496924768680636
> > Maybe your signal is to narrow compared to the overal band you are
> > with (or you have DS spread spectrum signal?).
> > Anyway, you will need to figure out which filter you want to use (e.g.,
> > butterworth for maximally flat characteristic in the passband, etc).
> > On 24 February 2010 09:33, <email@example.com> wrote:
> >> On Wed, Feb 24, 2010 at 8:12 AM, Nils Wagner
> >> <firstname.lastname@example.org> wrote:
> >> > Hi all,
> >> >
> >> > I have two questions concerning signal processing
> >> >
> >> > I have used scipy.stats.signaltonoise to compute the
> >> > signal-to-noise ratio.
> >> > The value is 0.0447.
> >> > How can I judge it ?
> >> It's just mean over standard deviation
> >> I never use it, but the interpretation will depend on what your
> >> level/mean/expected_value means.
> >> >
> >> > How can I filter out high frequencies using scipy ?
> >> > How can I eliminate noise from the signal ?
> >> (I'm no help here) There are many prefabricated filters in
> >> scipy.signal, but I only use lfilter.
> >> Josef
> >> >
> >> > Nils
> >> > _______________________________________________
> >> > SciPy-User mailing list
> >> > SciPy-User@scipy.org
> >> > http://mail.scipy.org/mailman/listinfo/scipy-user
> >> >
> >> _______________________________________________
> >> SciPy-User mailing list
> >> SciPy-User@scipy.org
> >> http://mail.scipy.org/mailman/listinfo/scipy-user
> > _______________________________________________
> > SciPy-User mailing list
> > SciPy-User@scipy.org
> > http://mail.scipy.org/mailman/listinfo/scipy-user
> SciPy-User mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the SciPy-User