ksdensity support parameter
Hi, I'm trying to estimate an inverse cdf and I'm having the following problems: When I estimate: x1 = ksdensity(x,u1,'function','icdf'); I get negative values for x1 even though the supports for both u1 and x are positive. When I try to correct this by estimating: x1 = ksdensity(x,u1,'function','icdf','support'... 10 Mar 2010 15:19
Generate random sample
Generate a random sample..from N samples and it should be even always, what should i add it i dont wana use loop thinng kn1=randperm(N); % Randomly eliminating some samples percent=.70 %70 percent kn2=kn1(1:ceil(percent*N)); % sorting random chosen traces in ascending order z=[sort(kn2)]; z should always be ... 26 Mar 2010 11:57
Frequency Plot to one third octave bar chart
Hi, I have sound pressure level and Frequency from the following: [MIC1,Faxis] = cpsd(mic1,mic1,win_shape,noverlap,block_len,fsamp); I can plat his as Sound Pressure Level vs Frequency giving but how do I get this in one third octave form, as in a bar chart with frequency on the x-axis and dB level on the y-axi... 5 Mar 2010 15:04
finding main path and branch from a graph(3D image)
I have a 3D image which contains a graph (centerline of a main vessel and its branch). I want to extract the main root and its separate branch in 3D. In our difinition the the main root is the longest path and it can be a curve structure in 3D. The line-end voxels (end of branch and main root or in the other view the ... 5 Mar 2010 15:04
Remove only concecutive repetitions in an array/matrix
One approach: B = A([true;logical(diff(A(:,2)))],:) ... 5 Mar 2010 15:04
Draw an one inch horizontal line?
It is kind of a silly question. But I cannot find a ruler in the office and I want to know how long is one inch. Since I have matlab and image processing toolbx, I think about just drawing a horizontal line in a figure window. But how would one draw a horizontal line (one inch long) in a figure window. I would li... 6 Mar 2010 12:57
more than 10 seconds on the scope??
I'm working on some control theory in Simulink. I have a step input and a transfer function. I want to see more than 10 seconds on the scope. Is this possible? ... 8 Mar 2010 16:24
Remove only concecutive repetitions in an array/matrix
Is there a way to remove only consecutive repetitions in an array? The UNIQUE function removes every other repietition irrespective of ther order For example I have a matrix as follows 1 6 2 6 3 5 4 20 5 18 6 7 8 5 9 5 10 5 11 20 12 6 the matirx after suppression of cons... 5 Mar 2010 13:56
New generator
How to create in Simulink the own generator, not one of standard approaches me. In advance thanks. ... 5 Mar 2010 13:55
Question about textscan
I'm using textscan to read in formatted data from text files. However the files don't have a set number of lines of data. The textfiles have a set amount of header lines (which I am using the 'headerlines' option in textscan to skip), then there is a random number of data lines. Then after the data lines, there is ... 5 Mar 2010 13:56