Respondida
MATLAB is missing one essential rounding function!
ceilfix = @(x)ceil(abs(x)).*sign(x); or some such nonsense name. ceilfix(-2:0.2:2)

casi 15 años hace | 2

| aceptada

Respondida
date formats
Assuming that all the dates are in BST and that you are not trying to adjust for different time zones ... x = 'Sat Oct 01 2...

casi 15 años hace | 1

| aceptada

Respondida
What does this error message mean - No class precondition specified for input 'x' of function 'square'.
What do you get with which square -all square is a function in the signal processing toolbox. Do you have any other fu...

casi 15 años hace | 0

Respondida
Exponential/Power curve fitting from data
I think if you log transform everything you can eliminate the fminsearch and treat the problem as optimizing a linear equation. ...

casi 15 años hace | 0

Respondida
Accessing values of a field of a dataset
You can use dynamic field names: myDS=dataset([1;2],[3;4],'VarNames',{'F1','F2'}); strFieldName = 'F1'; myDS.(strFiel...

casi 15 años hace | 1

| aceptada

Respondida
How could I neaten this code up.
x = [1 2]; eusol2 = 0; while sum(x) < euin if mod(sum(x), 2) == 0; eusol2 = eusol2 + sum(x); end x...

casi 15 años hace | 0

Respondida
String in matrix for loop
It really depends on what data type you are willing to allow. You say no structure and no array. MATLAB only deals with arrays; ...

casi 15 años hace | 0

Respondida
set variable to data that is loaded
x = load('matfile.mat'); temp = fieldnames(x); x = x.(temp{1});

casi 15 años hace | 1

| aceptada

Respondida
accessing functions in Statistics toolbox
I would try ver and license and license('test', 'statistics_toolbox') to see if the statistics toolbox i...

casi 15 años hace | 0

| aceptada

Respondida
How can I list all properties of a dynamicprops object ?
Can you use: properties doc properties Starting from the MATLAB example: <http://www.mathworks.com/help/releases/R201...

casi 15 años hace | 0

Respondida
Labelling x and y axis in MATLAB
Your best bet might be to use something like: <http://www.mathworks.com/matlabcentral/fileexchange/25298>

casi 15 años hace | 0

Respondida
How to properly use the ifft function ?
Working from Wayne's answer: x = randn(1000,1); xdft = fft(x, pow2(nextpow2(length(x)))); y = ifft(xdft); isreal(y...

casi 15 años hace | 0

Respondida
Create and indexing a matrix simultaneously
You cannot do it. See: <http://www.mathworks.com/matlabcentral/answers/1325-what-is-missing-from-matlab#answer_1931>

casi 15 años hace | 0

Respondida
Good programming practice...
Surprised Doug didn't chime in with his blog post: <http://blogs.mathworks.com/videos/2010/03/08/top-10-matlab-code-practices-th...

casi 15 años hace | 1

Respondida
Need help creating a loop
I wouldn't use a loop to do this (and I love loops). # How could you make z equal the sequence 1, 3, 5, 7, ..., N? # How cou...

casi 15 años hace | 2

| aceptada

Respondida
help with label
What type of single quotes are you using? It could be the code formating in my browser, but your quotes look funky.

casi 15 años hace | 0

Respondida
dimension mismatch??! i cant see how this can be a dimension mismatch?
The problem is that Dates2(i,1) is a scalar, but datestr(Dates(i,1),'dd-mm-yyyy ') returns a string with length...

casi 15 años hace | 0

| aceptada

Respondida
help with label
I am guessing you have a variable somewhere called xlabel. What do you get with which xlabel -all it should be something...

casi 15 años hace | 0

| aceptada

Respondida
running time
Since mat(i, 2) will always equal mat(j, 2) when i is equal to j and you will always set mat(i, 2) to zero unless it is already ...

casi 15 años hace | 1

Respondida
Memory Tweaking
In general you cannot tweak the memory allocated to MATLAB. Do you need all of s1_total in memory? Can you only work on a single...

casi 15 años hace | 0

Respondida
Separate words in a sentence.
As a first stab you could look at the running RMS power averaged over a short (20 ms) time window. Periods of low power are more...

casi 15 años hace | 0

Respondida
PaperSize In Normalized PaperUnits
set(gcf, 'PaperUnits', 'Normalized') set(gcf, 'PaperSize', [0.5, 1]) get(gcf, 'PaperSize') The setting of the paper s...

casi 15 años hace | 0

| aceptada

Respondida
Reading specific cell from several csvs
doc dlmread I cannot tell what row and column the number you need is. But assuming C13 means column 1 and row 13. file...

casi 15 años hace | 0

| aceptada

Respondida
in algorithm a~b , in MATLAB...??????
Assuming ~ mean not (or not equal) in your algorithm you could use ~= or ~isequal(). I prefer the isequal approach since it hand...

casi 15 años hace | 0

| aceptada

Respondida
findobj to refresh lines in a graph
Yes, it is easier if you create a handle ... if isfield(handles, 'line1') && ishandle(handles.line1) delete(handles.line...

casi 15 años hace | 1

| aceptada

Respondida
Creating 3D audio files
I have never used (or even heard of) roomism before. It looks nice. It seems like the roomism file is an impulse response. You s...

casi 15 años hace | 0

| aceptada

Respondida
downsampling a music in matlab
doc downsample Assuming your music is starting with a sample rate of 44.1 kHz and you are happy with a sampling rate of ~40...

casi 15 años hace | 0

| aceptada

Respondida
There is any function substituting for this 'for loops'?
I think with some reorganization you could transform the code so that it could be run in a parfor loop or on a cluster with the ...

casi 15 años hace | 0

Respondida
Profiler biases execution time of optimized code
In order to profile your code MATLAB needs to do a little extra work. In general, I think this extra work is minimal. In your ca...

casi 15 años hace | 0

Respondida
Pan a Plotted Curve with a Stationary Plot Behind
I cannot get it to easily work with plotyy, but I think with some work you could. That said, I am not sure there is a real advan...

casi 15 años hace | 1

| aceptada

Cargar más