Home > By category > Scripts >Communication > Estimatenoise



Estimatenoise

  • Downloads: 
  • Views: 
  • Rating:

Some curve fitting or smoothing tools can benefit from knowledge of the noise variance to expect on your data. Kalman filters use this information, also some spline fitting tools. So I wrote a function to extract the noise variance from a signal vector. It also works on any specified dimension of an array.

A few examples of this code in use:

Simple linear data, with purely additive N(0,1) gaussian noise:

t = 0:10000;
x = t + randn(size(t));
mv = estimatenoise(x)
mv =
1.0166

Gaussian noise added to a sine wave (Nominal variance = 0.01)
t = linspace(0,1,1000)';
x = sin(t*50) + randn(size(t))/10;
mv = estimatenoise(x)
mv =
0.0096887

Pure gaussian noise, with a nominal variance of 9. (Note that var would have been a better estimator for this particular case...)

mv = estimatenoise(3*randn(2,3,1000),3)
mv =
9.6584 8.2696 8.632
9.2404 8.5346 9.7725

A piecewise constant function with multiple discontinuities. The true noise variance should be 0.01.

t = linspace(0,1,1000);
X = round(cos(t*6*pi)) + randn(size(t))/10;
plot(t,X)
var(X) % var will be wildly in error
ans =
0.68256

estimatenoise(X)
ans =
0.010882

Test if estimatenoise is able to recover the variance of a normally distributed random sample with unit variance. (Yes, it will be much slower than var.)

mean(estimatenoise(randn(1000,1000)))
ans =
1.0002

Estimatenoise can now handle non-uniformly spaced series (by request.) In the next example,
the actual noise variance was 1.0 here. Perform the operation 1000 times, then look at the median variance estimate. How well did we do?

t = sort([randn(1,100) , randn(1,100)+5]);
X = repmat(sin(t*5)*100,1000,1) + ...
randn(1000,length(t));

Estimatenoise is clearly wrong when the spacing is ignored.

median(estimatenoise(X,2))
ans =
16.438

Supplying the sampling "times", we get quite a reasonable result.
median(estimatenoise(X,2,t))
ans =
1.1307

Estimatenoise also works on data with replicates. In this example, each point will be replicated up to 3 times. The actual noise variance was again 1.0 here. I'll also compare the increase in times required for estimatenoise when t is supplied.

t = sort([0:1:100, 1:2:100, 1:4:100]);
X = repmat(sin(t/10)*100,1000,1)+ ...
randn(1000,length(t));

Again, estimatenoise is clearly wrong when the non-uniform spacing is ignored.

tic,median(estimatenoise(X,2)),toc
ans =
4.2056
Elapsed time is 2.690135 seconds.

Supplying the sampling "times", we again get quite a reasonable result. The time penalty is not quite 2x.

tic,median(estimatenoise(X,2,t)),toc
ans =
1.0116
Elapsed time is 4.864486 seconds.

Free download from Shareware Connection - Some curve fitting or smoothing tools can benefit from knowledge of the noise variance to expect on your data.

Publisher: John D'Errico | License: Freeware | Price: 0.00
Version: 1.0 | Size: 10 KB | Platform: Matlab, Scripts
Released Date: 11-05-2013 | Rating: 0 | Title: Estimatenoise

Author Url: http://www.mathworks.com
Program Info Url: http://www.mathworks.com
Download Url: http://www.mathworks.com/matlabcentral/fx_files/16683/1/estimatenoise.zip

More downloads from Estimatenoise publisher John D'Errico:

fminsearchbnd - Fminsearch does not admit bound constraints.

The Fibonacci Sequence - Often I see students asking for help on a tool to compute the Fibonacci numbers

Fminsearchcon - Nonlinear optimization problems with bound constraints can be solved using FMINSEARCHBND (as well as using many other tools.)

Nonlinear Regression Shapes - The art of fitting a nonlinear regression model often starts with choosing a model form

Moving window standard deviation - Occasionally I see a request for computation of a running, windowed standard deviation.

Estimatenoise keywords:
Estimatenoise related downloads:

Random Sample Mapper - The Random Sample Mapper application was developed to be a small tool that moves random samples to a folder and makes an SFZ file.

Bug (kind-of) in randn() - This is a very strange bug in randn()

Random Number from Empirical Distribution - EMPRAND generates random numbers from empirical distribution of data.

Multivariate normal random vectors with fixed mean and covariance matrix - MVNRND2 Random vectors from the multivariate normal distribution.

Time index - >> help timeidx TIMEIDX returns numeric index given time string. D = TIMEIDX(T) returns index value in relative days which is suitable for DATENUM math. To work in hours multiply by 24, for seconds multiply by 24*3600, etc.

Shareware Connection periodically updates pricing and software information of 'Estimatenoise' from company source 'John D'Errico' , so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft,  Using 'Estimatenoise' crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of Estimatenoise.

New Reviews

SnapCrab - Nearly every PC users need to take screenshots from time to time, whether it is for personal or professional needs. While using the basic Windows screenshot capture method is available, it is not adequate for everyone. When you want to capture ...

CleanMyDrive - PC experts unanimously agree that using Macs tend to be a smoother and faster experience than running Windows based PCs but the Apple laptops and desktops also need maintenance and performance tweaking, occasionally. Regular web browsing, ...

360 Internet Security - Using a computer without having capable Security software installed is equivalent to sleeping with your house’s main door wide open. Whether you use a PC at home or manage a network of computers at the workplace, PC security suite has ...

Cyotek WebCopy - It will be hard to find a computer user nowadays who does not need to access the web. Using web has become near mandatory for various personal and professional reasons. However, not everyone who owns a computer and accesses the web is blessed ...

Bvckup - There is no denying the reality that computers have become a part and parcel of human existence. From education, work, entertainment and data storage, computers are required at every step of life. Safety of data is of paramount importance to PC ...

PC DeCrapifier - There is hardly any computer user who does not want to keep the PC running at top speed. However, unnecessary software and bloatware can reduce the speed and performance of your PC. Such Apps often come pre installed with laptops and desktops. ...

FortiClient Standard - Every computer user needs to have adequate protection for his system and this holds true for corporate and network users. In business setups, where multiple desktops and servers are connected to a network, using regular antivirus suite may be ...

Paint.NET - Nearly every PC user needs to use some type of image editing software nowadays, whether it is for personal or professional reasons. It can be for making minor corrections to your vacation pictures before you share them on social media sites. It ...

Groovy Media Player - There is hardly any PC user who does not listen to music while working on PC or at leisure time. For media playback on Windows PC, there are so many apps. You can opt for default WMP that comes with the OS. However, there are several other third ...

VLC Media Player Portable - There are plenty of media player applications available for Windows and some of the popular ones are actually freeware. If you find the Windows media player inadequate or sluggish, give VLC media player a try. This versatile media player plays ...




New Downloads

Folder Lock

Folder Lock is a data security
solution that encrypt &
secures your files, while
keeping an automatic and
real-time ...

MP3 Editor for Free

MP3 Editor for Free is perfect
for home-studio recording and
audio editing. It has dozens
of audio effects, audio ...

Coolutils Photo Viewer

The free Coolutils Photo
Viewer is the best way to
transfer photos from a camera
to the hard drive. Preview
images, ...

AlphaMenu Responsive jQuery
Mega Menu

ALPHAMENU is a user-friendly,
highly customizable and
responsive jQuery mega menu
plugin. It allows you to use
multiple ...

Preprocess CP2TFORM

When CP2TFORM is used in
piecewise linear image
transformation mode, it uses
triangulation to calculate the
local image ...

Optimal Distribution
Substations Placement using
Genetic Algorithm

This program uses an Excel
data file "DATA.xls" as an
input to the program. the
input file consists these
worksheets: ...

Mobile Comments Signature

The Mobile Comments Signature
plugin uses an efficient
script to detect comments made
from a mobile browser and then
...

Flashy

We found that there was a
shortage of flash video
wrapper players in the world
that were released under a
fully-Free license.

AtomatiCMS

AtomatiCMS is a simple-to-use
content management system that
caters for everyone; from
everyday users to web
developers.

Googlyzer

Googlyzer adds an
administrative dashboard to
WordPress with microcharts

Reference Preview

Allows users to preview the
content they are referencing
when editing a node-reference
field.

Clipping Indicator

Clipping is the main program.
There are three inputs: y is
the time record,
threshhold_value is the
clipping threshhold, ...