답변 있음
multiple line edit is not allowed on MATLAB file editor window?
The MATLAB Editor does not have this, I think. Do you have an example MATLAB source file you can share with us where this kind ...

8년 초과 전 | 0

답변 있음
Question on using a while loop?
To add the bet from the total, use: Bank = Bank + Bet; Subtraction will be similar, using "-" of course. To get your p...

8년 초과 전 | 0

답변 있음
Does matlab become slow and unusable when working in a folder with many files?
When you cd into a folder with 50,000 file, bear in mind that *all of these files are visible from MATLAB path*, and therefore m...

8년 초과 전 | 1

답변 있음
Can anyone help me with telling me how my variable is undefined?
You are writing a function that accepts 'temperature' as an input parameter. So, 'temperature' will exist inside your functions...

8년 초과 전 | 0

답변 있음
Applying multiple conditions to an 'if' statement
You might be looking for <http://www.mathworks.com/help/matlab/ref/logicaloperatorsshortcircuit.html logical operators>.

8년 초과 전 | 0

답변 있음
Mex can't find compiler after Xcode 7 update (R2015b)
*EDIT* MathWorks has produced a patch for this issue. If at all possible, use the procedure outlined at http://www.mathworks.co...

8년 초과 전 | 16

| 수락됨

답변 있음
Print out values in a while loop each time into an array.
A semicolon at the end of the line suppresses output [ <http://www.mathworks.com/help/matlab/matlab_prog/symbol-reference.html#b...

8년 초과 전 | 0

답변 있음
32 bit mex file not working in a 64 bit version of matlab
This is a stab in the dark, but a Google search found <https://github.com/filipjares/tdv/tree/master/src/gcs/private this on Git...

8년 초과 전 | 2

답변 있음
Tranform Python code in Matlab
MATLAB is 1-indexed, so I think you're looking for something like: diff = X(pairs(:,1),:) - X(pairs(:,2),:);

8년 초과 전 | 0

답변 있음
Read in file that has raw binary image data and an XML footer
You've got the right idea. Since you know the size of the image, open the mixed image/XML file with <http://www.mathworks.com...

8년 초과 전 | 0

| 수락됨

답변 있음
how to select a number randomly from a series of fixed number
>> a(randi(numel(a))) In other words, pick a random (integer) number _N_ between 1 and the number of elements in "a", then r...

8년 초과 전 | 0

| 수락됨

답변 있음
Why can parfor only write to one dimension?
From parfor's perspective, "result" is being accessed randomly. Try this instead: parfor i=index results1{i} = an...

8년 초과 전 | 0

답변 있음
How to do better commenting in Matlab script?
You'll get to the settings you need under "Home -> Preferences -> Editor/Debugger -> Display" and "Home -> Preferences -> Editor...

8년 초과 전 | 0

답변 있음
Generating a mex file from .m file
It looks like your system does not have the GNU C++ standard library installed. I believe this can be the case in some down dis...

8년 초과 전 | 0

답변 있음
How can I setup MATLAB to differentiate things like recent directories and command histories for two unrelated projects?
I don't think there is direct support for like this you describe. Path management can be semi-automated with scripts, but comma...

8년 초과 전 | 0

| 수락됨

답변 있음
Bug in matlab 2013b: all windows resize (get very small) when I right click in the Editor. It returns to normal only when program is restarted.
See <http://www.mathworks.com/matlabcentral/answers/122347-matlab-editor-windows-and-fonts-resize-get-smaller-on-right-click-why...

거의 9년 전 | 0

답변 있음
Why Matlab window gets smaller pressing right mouse button?
See <http://www.mathworks.com/matlabcentral/answers/122347-matlab-editor-windows-and-fonts-resize-get-smaller-on-right-click-why...

거의 9년 전 | 0

답변 있음
what is meant by this error" Dispatch Exception"?
That error is coming from Excel. Try basic mode: xlsread('extract2006.xlsx','foidev2006','','basic') Does this fare any ...

거의 9년 전 | 1

답변 있음
parallel computing speed question when the body of the parfor loop takes about 2 seconds
It really depends on what "dosomething" is doing. If it is pure computation, it should be a big win. If there is file or netwo...

거의 9년 전 | 0

| 수락됨

답변 있음
How to selectively import a column from a text file containing lot of headers
You can import all 57 columns with the following: txt=fileread('1.TXT'); % Read 57 numeric columns of data textscan(txt,...

거의 9년 전 | 3

| 수락됨

답변 있음
Simplify large for loop running average.
I've used the <http://www.mathworks.com/help/matlab/ref/filter.html filter> function perform moving average calculations -- seve...

거의 9년 전 | 0

답변 있음
I do not know why I am getting an error, i am trying to hand in this project but i will get a zero if the code can not be read. Please help me.
You cannot put function declarations inside a MATLAB script. Cut 'n' paste each function into its own file, naming the files p2...

거의 9년 전 | 0

답변 있음
How to divide a matrix into smaller matrices
Try <http://www.mathworks.com/matlabcentral/answers/89757-how-to-divide-256x256-matrix-into-sixteen-16x16-blocks this Answer>. ...

거의 9년 전 | 0

답변 있음
I do not understand this error message
MATLAB is trying to preform matrix multiplication when I think you want element-by-element multiplication instead. Replace * (a...

거의 9년 전 | 0

답변 있음
How to read a console data
Do you mean the text created by something you run on the command line? Use the system command's second output argument: >> ...

거의 9년 전 | 0

답변 있음
xlsread unable to import data or sorts the imported data. please advice.
Nitin, I was able to load this 20 times in a row without issue. But, I am on Mac, which uses quite a different code path than a...

거의 9년 전 | 0

| 수락됨

답변 있음
Using matlab command from VS2013/C++ system() call to exeute a script - fprintf issue
You self-diagnosed well. Windows' working folder is different in the two scenarios. When you start MATLAB *not* from the Start...

거의 9년 전 | 0

| 수락됨

답변 있음
How to change certain lines in a file?
As Per states, you can't edit an existing file unless the changes are exactly the same size (number of bytes) as the original, w...

거의 9년 전 | 0

답변 있음
xlsread unable to import data or sorts the imported data. please advice.
I can answer question #2, I think. If you have two separate variables and you sort one, then, yes, the two variables will now b...

거의 9년 전 | 0

답변 있음
64 bit matlab coder and Visual Studio compiler.
Visual C++ 2013 include a 64-bit compiler, it should work just fine. <http://www.mathworks.com/support/compilers/R2015a/index...

거의 9년 전 | 0

더 보기