Info

This question is closed. Reopen it to edit or answer.

Help with functions interpolation number generation

1 view (last 30 days)
Martin
Martin on 2 Apr 2014
Closed: MATLAB Answer Bot on 20 Aug 2021
I have a given function gen_cdf_weibull that outputs a 100x2 array but I'm trying to define this array as weibull_cdf and i dont know how. I have coded to generate a random number y and interpolate for it's corrosponding x value from weibull_cdf but it obviously doesnt work as it's not defined. here's what i've got so far
gen_CDF_Weibull
y=rand() x= interp1(CDF_Weibull(:,2), CDF_Weibull(:,1), y)
(gen_cdf_weibull is saved as a seperate script) I want to run a forloop 8766 times of this number generation and interpolation but not sure how to do that either as I've never managed to get my head around loops!!! thnx in advance for any help given

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!