View difference between Paste ID: yTRahzr5 and x9zMQRxv
SHOW: | | - or go back to the newest paste.
1
%% what I want to do:
2
x_true % "true", error-free measurement of a variable over time
3
x_noise % synthetic noise, not necessarily homoskedastic and/or normally distributed
4
x = x_true + x_noise
5
for i = 1:n_boot
6
    p_est(i) = parameter for best fit of model to x
7
    x = x_true + resample( x_noise ) % bootstrap x_noise (I guess wild bootstrap would be best here?)
8-
    end
8+
end
9
10
%% what I believe "normal" bootstrapping of residuals would look like ???
11
for i = 1:n_boot
12
    p_est(i) = parameter for best fit of model to x
13
    x = x_first_best_fit + resample( x_first_best_fit - x )
14
end