답변 있음
Opening many excel files into different matrices
A cell array would be ideal. Example: list = {'file1.xls','C:\data\file2.xls', ....}; for i = 1:numel(list) data{i} = x...

11년 초과 전 | 1

| 수락됨

답변 있음
Error:Subscript indices must either be real positive integers or logicals
The simple answer, which should work is to drop all of the (x) you've got. The reason being that it looks like you're confus...

11년 초과 전 | 0

답변 있음
How can i get the x value for a chosen y value?
[maxY index] = max(abs(wave)); index is either the X value, or something you can use to get the x values, eg, x = 1...

11년 초과 전 | 1

| 수락됨

답변 있음
how can give an image as input in a fuction?
Ok, if by "image" you mean filename, then you can do it like this: folder = 'C:\My Images\'; files = dir([folder '\*.jpg...

11년 초과 전 | 0

답변 있음
Please help me with this simple problem? Confusing
Is the tolerance as simple as being the "epsilon" of the numbers involved? The machine epsilon is the smallest number that c...

11년 초과 전 | 0

답변 있음
Remove vertical stripping noise
Here's an answer that probably hits what you need... column_offsets = median(im); column_offsets = column_offsets - min(co...

11년 초과 전 | 3

답변 있음
Matlab2014a pcode and functions: cannot generate pcode due to input argument error?
I know this is probably obvious, but you are using "pcode" correctly? pcode filename or pcode('filename')

11년 초과 전 | 0

답변 있음
indexing a variable in matlab
The normal right answer is to just use arrays. This limits you to using normal indexing techniques (logical & positive integer) ...

11년 초과 전 | 2

| 수락됨

답변 있음
how to use image in exterma mfile?
Ok, I'll translate the problems: Undefined function 'extrema' for input arguments of type 'uint8'. That means that the ex...

11년 초과 전 | 0

| 수락됨

답변 있음
plotting without displaying in an m file which calls another .m file
saveas will let you save figures. figures can be invisible. fig = figure('visible','off'); axis_id = gca; plot(axis_id,...

11년 초과 전 | 0

답변 있음
how to find indices that fulfil a certain criteria
after_7 = 1:numel(vector) > 7; after_17= 1:numel(vector) > 17; twos_after_7 = vector == 2 & after_7; twos_after_17 = vect...

11년 초과 전 | 1

| 수락됨

답변 있음
Absorption of heat by laser light into material, calculation
You need to get the physics clearer. 1. Reflection, by the plastic, of the laser light will reduce the energy absorbed. ...

11년 초과 전 | 0

답변 있음
Creating variable name using sprintf and field of a structure
I agree with the advice to NOT name dynamically name variables in a loop. It more often leads to pain than not. You would be...

11년 초과 전 | 0

답변 있음
Plotting data from struct
plot(someStruct.a, someStruct.c,'k-o') That's the answer to the question you're asking. I suspect that ACTUALLY, you wan...

11년 초과 전 | 0

답변 있음
Using Mathlab with Ruby
I asked a similar question a couple of weeks ago and haven't managed to do much with it. http://www.mathworks.co.uk/matlabce...

11년 초과 전 | 0

답변 있음
Help: Excel manipulation in Matlab
You probably don't need a for loop: The function "xlsread" reads in the contents of an entire sheet (ALL columns), by default...

11년 초과 전 | 0

| 수락됨

답변 있음
Automatic import of Spread sheet data
It is possible to use a macro in excel that will tell matlab, in some way, if it has been updated. It is also possible to ju...

11년 초과 전 | 0

| 수락됨

답변 있음
MATLAB date conversion and analysis
Matlab datenum follows the convention of "day = 1" "hour = 1/24" "minute = 1/(24*60)" If today has the value of 5235...

11년 초과 전 | 0

답변 있음
uigetfile only let me choose file from the current folder.how can i choose from anywhere?
selected=sprintf('%s',filename); should be selected=sprintf('%s',fullfile(pathname,filename));

11년 초과 전 | 0

| 수락됨

답변 있음
M-file created in previous version, not working in advanced version.
I've found that simulink files don't always transfer neatly from one version of matlab to a newer version. You'll likely find th...

11년 초과 전 | 0

답변 있음
Using a variable in fopen
init = 'W:\Examples'; folder = dir(init) for i = 1:numel(folder) % do something with folder(i) to figure out if it's ...

11년 초과 전 | 0

| 수락됨

답변 있음
Adding parameter to file name string when saving a figure as a jpeg
filename = ['Point cloud ' num2str(5) '.jpg']; saveas(1,filename)

11년 초과 전 | 2

답변 있음
Problem of writing a mixed type cell array to a csv file
If you want to write it as a csv file and if it must be a csv file and the data is really variable format, then you may have to ...

11년 초과 전 | 0

답변 있음
Set a time limitation on algorithms
I may have an answer: Matlab can be used to manage "parallel" computing jobs. One of the methods allows Matlab to stipulate a...

11년 초과 전 | 1

답변 있음
Help with average of elements in a matrix
n=4 elements = numel(M); sets = round( elements / n / size(M,2)); elements_to_use = sets * n * size(M,2); Mnew = squeez...

11년 초과 전 | 0

답변 있음
Advanced fitting to analytical functions
"fit" will try to fit specified functions. - You'll need to play around with it. There's a 3rd party thing called Eureqa tha...

11년 초과 전 | 0

| 수락됨

답변 있음
Combining two matrices of the same size to create a new matrix where each cell contains both values from the parent matrices.
You've got 2 options: 1. Create a 240 x 320 _x 2_ matrix: (or 2 x 240 x 320 or whatever) C(:,:,1) = distance_map; C(:,:...

11년 초과 전 | 0

| 수락됨

답변 있음
Save Matrix values when values change from NaN to a Number in MATLAB
if you ONLY get nans in entire columns, this'll work: numbers = oldmatrix(~isnan(oldmatrix)); numbers = reshape(numbers, 3...

11년 초과 전 | 0

답변 있음
Storing points into an array
p = img(75, 104,:);

11년 초과 전 | 0

답변 있음
Using all values in a matrix as inputs for a function.
You need to distinguish the fact that matlab, by default, does matrix multiplication, division and powers by the actual matrix m...

11년 초과 전 | 0

| 수락됨

더 보기