Risposto
Get to selected 2d matrix from a 3d matrix
SLICES = mat(:,:,1:3:45);

oltre 15 anni fa | 0

| accettato

Risposto
how to search for bugs
<http://www.mathworks.com/search/advanced_search.html?query= Here> is a way to select Bug Reports, then do the search.

oltre 15 anni fa | 0

Risposto
loops
Is this what you are looking for? A=1.687; gamma=1.4; tol=1e-4; IDX = 0:.0001:2; z = zeros(1,length(IDX)); % Pre...

oltre 15 anni fa | 0

Risposto
For loope small increments
I don't know why you think this starts at 2.910. Perhaps you are running into the limit of your command window when trying to s...

oltre 15 anni fa | 1

| accettato

Risposto
Comparing two matriced
And a visual method: spy(A~=B) And a quick method to count the number of locations where A is not equal to B: nnz(A~=B)

oltre 15 anni fa | 0

Risposto
Need help in evaluating integral with quad
Or, you can do it in one shot with QUADV: th = 0.01:0.1:2*pi-0.01; f = @(x)(exp(-0.5*x).*sin(x*2*sin((th)/2))); born =...

oltre 15 anni fa | 1

Risposto
how to save a .mat file full of characters into a .txt file?
You don't say what form dictionary takes. Is it a cell array, a character array, or what? In general, use the FWRITE functio...

oltre 15 anni fa | 1

Risposto
Reading text from a txt file into a cell array
What does the data on each line look like? Does it follow a pattern? Post one of the lines if all lines follow a similar patte...

oltre 15 anni fa | 1

Risposto
Connect the dots
This problem might be solved more easily and efficiently, but this solution should get you through your example. Walter's conce...

oltre 15 anni fa | 0

| accettato

Risposto
Hump-day challenger - Recursion
O.k., here is something I do not understand. In trying to make the original algorithm I published (reproduced below) more effic...

oltre 15 anni fa | 0

Risposto
Hump-day challenger - Recursion
O.k., here is my other idea. It first sorts the array then uses a much more efficient recursive method than the algorithm I pos...

oltre 15 anni fa | 1

Risposto
Subplot in PlotButton Callback: Can a subplot be incorporated into the code of a plot button?
I think you must mean that you want a new subplot with each button press, is that correct? If so, do you want to limit the numb...

oltre 15 anni fa | 0

Risposto
Plot Button Callback: Labeling Resulting Plot Axes and Title
The TITLE, XLABEL and YLABEL functions all take an axes as the first argument. So after you do the plotting, call the functions...

oltre 15 anni fa | 0

| accettato

Risposto
Numerical integration of double integrals in MAtlab
Look at the TRAPZ function.

oltre 15 anni fa | 0

Risposto
Trouble with for loop
As others have suggested, this is not "trouble with a FOR loop," but trouble with the way you are approaching the problem. You ...

oltre 15 anni fa | 0

Risposto
What is the best way to rotate a 3D dataset about the Y axis
Use the ROTATE function. For help on how to use the function, type: help rotate

oltre 15 anni fa | 0

Risposto
Label a plot
Use the TEXT function. To see the help, use: help text In your case: z = 100; y=get(gca,'ylim'); h=plot([z z],y,'-r');...

oltre 15 anni fa | 0

| accettato

Risposto
Best File Exchange ever !!!
John D'Errico's <http://www.mathworks.com/matlabcentral/fileexchange/22725 Variable Precision Integer Arithmetic> toolbox is awe...

oltre 15 anni fa | 3

Risposto
Best File Exchange ever !!!
I hope it doesn't sound arrogant, but the only file from the FEX POTW which I *literally* use several times _every single day_ i...

oltre 15 anni fa | 2

Risposto
MATLAB File read Stuck on 1 Line
Why not just use the TEXTSCAN function instead of textread? This way you avoid the loop and read the whole file in one shot. J...

oltre 15 anni fa | 0

Risposto
Problem with plotting
For the first question, use the LEGEND command. L = length(get(axeshandle,'children')); legend([repmat('t',L,1),sprintf('...

oltre 15 anni fa | 2

| accettato

Risposto
field delimiter uses any char as to declare a new field instead of full string
Just so you understand what happened when you set the delimiter to 'locus=', MATLAB interprets the delimiter property as a list ...

oltre 15 anni fa | 1

Risposto
creating different arrays on the fly
Just in case you didn't read the link Paulo gave, DON'T DO THIS! You will end up way too many variables, then you will be ask...

oltre 15 anni fa | 4

| accettato

Risposto
Pulling specific data from a matrix, and starting a new matrix
Use the NNZ function to count the number of nonzeros. Use logical indexing to get the nonzeros. nzA = A(A~=0)

oltre 15 anni fa | 0

Risposto
Matlab delete values
A(find(A==T,1,'first')) = []; Or, you could just use Index directly: A(Index(1)) = [] And avoid the call to FIND and/or a...

oltre 15 anni fa | 0

Risposto
How to link the contain of one push button to another in MatLab GUI?
In the callback for the pushbutton, get the string and value of the listbox and use the value as an index into the string. C ...

oltre 15 anni fa | 0

| accettato

Risposto
Problems with while expression in a script
As Walter intimates, this is a floating point issue. Instead of using a tolerance, you might want to think about the problem at...

oltre 15 anni fa | 0

Risposto
Please help me creating help button please!!
For very complicated GUIs, why not just use another GUI as the helper? For example, just make another GUI which has different c...

oltre 15 anni fa | 0

| accettato

Risposto
How to interrupt the progrom in a GUI
You can call ctrl+c by using a Java Robot, but it won't do what you want. This is because the program which is running will pre...

oltre 15 anni fa | 2

Risposto
how do I modify the axis in plot(x,y)?
Is this more to your liking? x=[0.05 0.1 0.3 0.5 1 5 10 20 30 40 50]; y=[0.8 0.83 0.9 0.93 0.93 0.9 0.9 0.94 0.95 0...

oltre 15 anni fa | 0

Carica altro