Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
bootstrap

Subject: bootstrap

From: Corinne

Date: 1 Apr, 2008 20:05:05

Message: 1 of 10

Hi all,
  I am having difficulties understanding the multiple
bootstrap functions available. I have been working with
bstrap and bootstrp. What I have is a 56x13 matrix,
represents data within grid boxes. I want to run 100 random
iterations of the data, and end up with the average rms
values at each grid box, or for each 56x13.

for the function bstrap(b,f,fun,x,varagin). I am having a
difficult time understanding what each variable means.
b=570 (the number of sample points i have), f=1, fun='rms'
and x=my data in rows. When I do this, I get back a 1x1x571,
all of the same number. And then I am still unsure how to
average 100 iterations...

Thanks in advance for any help!!
-Corinne

Subject: bootstrap

From: Peter Perkins

Date: 2 Apr, 2008 17:56:30

Message: 2 of 10

Corinne wrote:
> Hi all,
> I am having difficulties understanding the multiple
> bootstrap functions available. I have been working with
> bstrap and bootstrp. What I have is a 56x13 matrix,
> represents data within grid boxes. I want to run 100 random
> iterations of the data, and end up with the average rms
> values at each grid box, or for each 56x13.

Corrine, bstrap is from the FEX, I think, and I'm not familiar with it.

BOOTSTRP is typically used to resample from data, compute some estimate
on each bootstrap sample, and then do something with the resulting
"bootstrap sampling distribution" of the bootstrap estimates. Often,
the final answer is the std dev of the bootstrap estimates.

 From your description, it's hard to tell what your data represent,
whether or how they are an independent sample (and therefore how you
want to resample them), and what estimate you're bootstrapping. It
almost sounds like you want to do a stratified bootstrap, but it's hard
to tell from your description.

Subject: bootstrap

From: Corinne

Date: 2 Apr, 2008 22:12:01

Message: 3 of 10

Thanks Peter, I'll try to explain it a bit better.
So essentially what I would like to do is re-sample the data
100 times, and take the average rms value at each point. So
I have a 56x13 matrix of gridded and interpolated ocean
tracer data. I would like to get back a 56x13 matrix of the
average rms values for each point in the matrix. From this,
I wnat to plot the average rms data to look at where the
highest/lowest areas of errors are and generate a total
error on my data. Hopefully that makes more sense? Thank
you so much!
-C


Peter Perkins <Peter.PerkinsRemoveThis@mathworks.com> wrote
in message <ft0hce$hh$1@fred.mathworks.com>...
> Corinne wrote:
> > Hi all,
> > I am having difficulties understanding the multiple
> > bootstrap functions available. I have been working with
> > bstrap and bootstrp. What I have is a 56x13 matrix,
> > represents data within grid boxes. I want to run 100 random
> > iterations of the data, and end up with the average rms
> > values at each grid box, or for each 56x13.
>
> Corrine, bstrap is from the FEX, I think, and I'm not
familiar with it.
>
> BOOTSTRP is typically used to resample from data, compute
some estimate
> on each bootstrap sample, and then do something with the
resulting
> "bootstrap sampling distribution" of the bootstrap
estimates. Often,
> the final answer is the std dev of the bootstrap estimates.
>
> From your description, it's hard to tell what your data
represent,
> whether or how they are an independent sample (and
therefore how you
> want to resample them), and what estimate you're
bootstrapping. It
> almost sounds like you want to do a stratified bootstrap,
but it's hard
> to tell from your description.

Subject: bootstrap

From: Peter Perkins

Date: 3 Apr, 2008 11:56:42

Message: 4 of 10

Corinne wrote:
> Thanks Peter, I'll try to explain it a bit better.
> So essentially what I would like to do is re-sample the data
> 100 times, and take the average rms value at each point. So
> I have a 56x13 matrix of gridded and interpolated ocean
> tracer data. I would like to get back a 56x13 matrix of the
> average rms values for each point in the matrix. From this,
> I wnat to plot the average rms data to look at where the
> highest/lowest areas of errors are and generate a total
> error on my data.

Corinne, in order to use the bootstrap properly, you need to define how
your bootstrap samples will be drawn from your original data, and that
requires you to think about how your data were originally sampled,
whether they are independent and identically distributed or not, and if
not, what component of your data is independent and identically distributed.

The book by Efron&Tibshirani is a good introduction, you might find it
helpful.

Subject: bootstrap

From: Corinne

Date: 3 Apr, 2008 15:25:04

Message: 5 of 10

Peter Perkins <Peter.PerkinsRemoveThis@mathworks.com> wrote
in message <ft2glr$bu2$1@fred.mathworks.com>...
> Corinne wrote:
> > Thanks Peter, I'll try to explain it a bit better.
> > So essentially what I would like to do is re-sample the data
> > 100 times, and take the average rms value at each point. So
> > I have a 56x13 matrix of gridded and interpolated ocean
> > tracer data. I would like to get back a 56x13 matrix of the
> > average rms values for each point in the matrix. From this,
> > I wnat to plot the average rms data to look at where the
> > highest/lowest areas of errors are and generate a total
> > error on my data.
>
> Corinne, in order to use the bootstrap properly, you need
to define how
> your bootstrap samples will be drawn from your original
data, and that
> requires you to think about how your data were originally
sampled,
> whether they are independent and identically distributed
or not, and if
> not, what component of your data is independent and
identically distributed.
>
> The book by Efron&Tibshirani is a good introduction, you
might find it
> helpful.

Thanks for the reference, I'll take a look at that.
-C

Subject: bootstrap

From: Peter Perkins

Date: 3 Apr, 2008 15:35:32

Message: 6 of 10

Peter Perkins wrote:
> Corinne wrote:
>> Thanks Peter, I'll try to explain it a bit better. So essentially what
>> I would like to do is re-sample the data
>> 100 times, and take the average rms value at each point. So
>> I have a 56x13 matrix of gridded and interpolated ocean
>> tracer data. I would like to get back a 56x13 matrix of the
>> average rms values for each point in the matrix. From this,
>> I wnat to plot the average rms data to look at where the
>> highest/lowest areas of errors are and generate a total
>> error on my data.
>
> Corinne, in order to use the bootstrap properly, you need to define how
> your bootstrap samples will be drawn from your original data, and that
> requires you to think about how your data were originally sampled,
> whether they are independent and identically distributed or not, and if
> not, what component of your data is independent and identically
> distributed.

To me, it sounds like your matrix of data represents a spatial
configuration, and somehow your bootstrap samples would have to preserve
that, and so perhaps you need a stratified bootstrap. But it sunds like
you have only one sample in each stratum, which means you can usefully
bootstrap.

Subject: bootstrap

From: Peter Perkins

Date: 3 Apr, 2008 16:43:26

Message: 7 of 10

Peter Perkins wrote:

> To me, it sounds like your matrix of data represents a spatial
> configuration, and somehow your bootstrap samples would have to preserve
> that, and so perhaps you need a stratified bootstrap. But it sunds like
> you have only one sample in each stratum, which means you can usefully
> bootstrap.

Sorry, I meant to say, "you canNOT usefully bootstrap".

Subject: bootstrap

From: Corinne

Date: 3 Apr, 2008 17:00:20

Message: 8 of 10

Peter Perkins <Peter.PerkinsRemoveThis@mathworks.com> wrote
in message <ft31fe$7jm$1@fred.mathworks.com>...
> Peter Perkins wrote:
>
> > To me, it sounds like your matrix of data represents a
spatial
> > configuration, and somehow your bootstrap samples would
have to preserve
> > that, and so perhaps you need a stratified bootstrap.
But it sunds like
> > you have only one sample in each stratum, which means
you can usefully
> > bootstrap.
>
> Sorry, I meant to say, "you canNOT usefully bootstrap".

I'm trying to replicate previous methods published in a few
journals using a different data set. I do have a spatially
dependent data set, based on latitude and longitude, and the
more I read on bootstrapping and from your comments the less
I am thinking that this is a viable way of estimating the
error. What I want to get at is an error from interpolating
and contouring across areas that have no actual data points.
 Any other statistical methods to get a handle on this?
Thanks again for your help.

Subject: bootstrap

From: Peter Perkins

Date: 4 Apr, 2008 14:28:18

Message: 9 of 10

Corinne wrote:

> What I want to get at is an error from interpolating
> and contouring across areas that have no actual data points.
> Any other statistical methods to get a handle on this?

You may be able to do what's know as a "parametric bootstrap". If you
have some idea of the variability (and hopefully sampling distribution)
in the individual observed values on your spatial grid, then you could
simulate new values on the grid, and compute an interpolated value. DO
that a zillion times, and you get an idea of how variable the
interpolated values are.

MATLAB is good at this.

Subject: bootstrap

From: carlos lopez

Date: 4 Apr, 2008 14:57:01

Message: 10 of 10

"Corinne " <chartin@rsmas.miami.edu> wrote in message
<ft32f4$iqj$1@fred.mathworks.com>...
> I'm trying to replicate previous methods published in a few
> journals using a different data set. I do have a spatially
> dependent data set, based on latitude and longitude, and the
> more I read on bootstrapping and from your comments the less
> I am thinking that this is a viable way of estimating the
> error. What I want to get at is an error from interpolating
> and contouring across areas that have no actual data points.
> Any other statistical methods to get a handle on this?
You are right; if you just have one realization of the data
you cannot apply bootstrap.
The solution for your problem is geostatistics; look for
"kriging", "variogram", etc. There exist some contributions
(EasyKrig, etc.) which might be helpful
Regards
Carlos

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us