已回答
how to fetch files from each sub directory?
Use the _dir2_ function. With it, you can fetch files recursively.

11 years 前 | 0

已回答
Find a series of consecutive numbers in a vector
my_array = [34 35 36 78 79 80 81 82 84 85 86 102 103 104 105 106 107 201 202 203 204]; my_num = 0; consec = 1; for k...

11 years 前 | 2

已回答
how to use dir2 function in matlab?
If you just downloaded the function _dir2_ and place it in a location whose path is added to the system, it's bound not to work....

11 years 前 | 0

已回答
How can I download an earlier version of matlab?
You should contact a mathworks sales agent. They will give you a solution. Anyway, I would recommend you to update your OS inst...

11 years 前 | 0

已回答
fopen and xlswrite error
close the file before attempting the its opening: fod = fopen(outputfile,'w'); fprintf(fod, '%s \t%s \t%s \t%s \t%s \t%...

11 years 前 | 0

已回答
how to access a particular format files from a drive location?
try the function given in the following link for recursive search: <http://www.mathworks.com/matlabcentral/fileexchange/40016...

11 years 前 | 0

已回答
Too many input arguments-ga mixed integer optimiazation
Instead of using _optimset_ to set the options use _gaoptimset_.

11 years 前 | 0

已回答
Save GUI axes .jpg (cut-off)
Use _print_ instead: print('-dpng',your_fig_name); or in jpg format: print('-djpeg',your_fig_name);

11 years 前 | 0

已回答
RGB 2 L*A*B*
LAB (:,:,1) can have values above 100. See if the following code (taking from matlab documentation) works on your machine: ...

11 years 前 | 0

| 已接受

已回答
Can you set the name for a fit when you call the cftool(x,y) gui?
You can not do it with _cftool_, but you can code it instead usign _fit_, like this: Fit = 'my_fit'; [xData, yData] = pr...

11 years 前 | 0

| 已接受

已回答
plotting two vectors on same graph
Scale the array with smallest range, like in this example: Not scaled data: x=1:500; y=rand(500,1); plot(x,y) h...

11 years 前 | 0

已回答
How do you type the future value annuity formula?
P = periodic_payment; r = rate_of_period; n = number_of_periods; FV_of_Annuity = P*( ( (1*r)^n-1 )/r );

11 years 前 | 0

已回答
What's the problem in my loop?
Your code should go like this: A=imread('cameraman.tif'); B=zeros( size(A) ); for j=1:size(A,1) for k=2:(size(...

11 years 前 | 0

| 已接受

已回答
Leave the whole for-loop
The _break_ command exists the most inner for/while loop. For nested for loops, you have to set a flag so that when it is active...

11 years 前 | 0

已回答
problem with binary code
In your case, the relative frequency of the sequence: 0 0 1 1 is 0,0701754385964912 Then,it means that if you take your ...

11 years 前 | 0

已回答
Can we get a handle of any .exe file running in Windows using m-scripts ?
Generally speaking, it is NOT always possible. But it all depends on the way the other interface was programmed.

11 years 前 | 0

已回答
Problem in function handling using callback functions GUI
You say your GUI has an edit box and a push-button, you should have a callback function for each object in your GUI, then, the c...

11 years 前 | 2

已回答
add vertical lines to an image
The following draws a vertical line on your_image from pixel (20, 10) to pixel (20, 50): image(your_image); hold on x...

11 years 前 | 0

已回答
how to call path location in global to a function in matlab?
Since _add_ is a matlab built-in function, you should not use it to name your own functions. If path_01 and path_02 are const...

11 years 前 | 0

已回答
How can convert .mdl to .m
To go from your simulink model to a m-file you have to re-write your model into matlab code. There is not a command to transform...

11 years 前 | 0

已回答
Stuck with one program
I wrote the first part of your exercise, try to do the rest yourself: Fm = input('value of Fm? '); T = input('value of T...

11 years 前 | 0

已回答
DC Motor Drive thru Serial port using MATLAB
The commands to send through the serial port to control your DC motor shoud be in the motor data-sheet. Every piece of hardware ...

11 years 前 | 0

已回答
how to access a particular format files from a drive location?
The following will return a struct containing the .zip files in the folder specified by _path_to_zip_files_: my_zips = di...

11 years 前 | 0

已回答
how to make unzip faster in matlab?
You can try something like this: my_zips = dir('*.zip'); for k=1:numel(my_zips) tmp_str = horzcat('unzip ', my_zi...

11 years 前 | 0

已回答
How to "save as" a processed graph as a .txt data file?
If you put your data into a cell array, you can easily save it into a .txt file using _dlmcell.m_ from fileexchange: < http...

11 years 前 | 0

已回答
how to make unzip faster in matlab?
You can use external software with " ! ", if you use _unzip_, then, call it this way: ! unzip your_file.zip

11 years 前 | 2

已回答
two listboxes in a GUI
To set the list of numbers on the your list2, this has to be done by setting the 'String' property of list2. The list of element...

11 years 前 | 0

| 已接受

已回答
LISTBOX, PLEASE HELP ME WITH THE LISTBOX
The array has to be transformed into a cell arrary: a=1:1:10; b=num2cell(a); Then, send it to the popup menu: se...

11 years 前 | 1

| 已接受

已回答
Control simulink model with Matlab
Use the _set_param_ function. For a model called _test_, with a constant block named "Constant_2" on it, you can use: my...

11 years 前 | 0

已回答
how do i vectorise given code?
If X is your matrix, here is how you get a 4x4 cell array out of your original matrix: X = rand(20); Y = mat2cell(X, rep...

11 years 前 | 0

加载更多