Réponse apportée
Import single raws from excel using the find function.
You should use the first return values from xlsread to read numberical data, such as year = xlsread('ESCvinnere-2','A1:E64'...

plus de 10 ans il y a | 0

Réponse apportée
Is it possibe to find the equation from two data vector like x=0 10 20 30 40 50 60 y=78.54 76.19 73.65 70.86 67.72 64.20 60.19
You can use polyfit to fit a polynominal to your data. A polynominal of order 2 gives a nice fit p = polyfit(x, y, 2); p...

plus de 10 ans il y a | 0

Réponse apportée
How to read text files from different sub folders in a folder ?
Use getAllFiles from <http://stackoverflow.com/questions/2652630/how-to-get-all-files-under-a-specific-directory-in-matlab/26449...

plus de 10 ans il y a | 0

Réponse apportée
convert hexadecimal to string
hexnum = '63727970746F'; num = hex2dec(hexnum)

plus de 10 ans il y a | 0

Réponse apportée
XTick labels and Stacking in bar plot
1. bar(1, PErr(1),'FaceColor', 'r') hold on bar(2, PErr(2),'FaceColor', 'b') set(gca, 'XTick', [1 2]) set(gca,...

plus de 10 ans il y a | 5

| A accepté

Réponse apportée
How do I access array elements in for loop?
K = [2 5]; for i = 1:2; B(i) = 2*K(i); end D = B(1) E = B(2) F = 3*D^2 + 4*E^2 G = 3*D*E + 4*D*E This could...

plus de 10 ans il y a | 0

| A accepté

Réponse apportée
What exactly algorithm does MATLAB use in the function imadjust?
You can have a look at the source code of imadjust to see what Matlab is doing. type imadjust or edit imadjust (...

plus de 10 ans il y a | 0

Réponse apportée
converting binary to hexadecimal
You have a script and try to define a function in line 19. This is not allowed. You have to either define b2h in a different fil...

plus de 10 ans il y a | 0

| A accepté

Réponse apportée
How to add a legend for bar and line plot on one figure?
x = rand(10, 4); h(:, 1) = bar(x) h(:, 2) = plot(x) legend(h(:), {'A' 'B' 'C' 'D' 'E' 'F' 'G' 'H'})

plus de 10 ans il y a | 0

Réponse apportée
Error: In an assignment A(I) = B, the number of elements in B and I must be the same.
I think it shouldn't be diff(i) but Diff(i) There are some further issues with your code; You define BatteriLaddni...

plus de 10 ans il y a | 0

| A accepté

Réponse apportée
How can I convert a vector to 2D matrix correctly?
That's correct. Note that reshape works along order of dimensions, so in this case the first 177 values of A would go to the fir...

plus de 10 ans il y a | 1

Réponse apportée
Is it possible to extract bars from the hist or histogram function?
The values you are looking for are returned by the histogram function: h = hist(x); plot(h)

plus de 10 ans il y a | 1

Réponse apportée
write an equation from algorithm
It interpret your question such that you do not ask for the equation, but for the Matlab implementation. It's pretty straigh...

plus de 10 ans il y a | 0

Réponse apportée
What is this power function doing?
I guess it computes 10.^(PD/10).

plus de 10 ans il y a | 0

Réponse apportée
How to create many variables from a dataset?
You can reshape your data data = reshape(data, 26, 14198, 2); You can even let Matlab figure out the elements along the...

plus de 10 ans il y a | 0

Réponse apportée
How can I implement these equations in Matlab programming?
If you have your height values in a 2D matrix Z, use sa = mean2(abs(Z)); sq = sqrt(mean2(Z.^2)) sz = max(Z(:)) - min(Z(:...

plus de 10 ans il y a | 1

Réponse apportée
Plot different values with different axes
help plotyy

plus de 10 ans il y a | 0

Réponse apportée
Format Issues - will not accept a character or a double
It would be helpful to know 1) what you want to achieve in your code and 2) how are the variables defined, like x_src_c, X_rot, ...

plus de 10 ans il y a | 0

Réponse apportée
What's the effect to start up Matlab with -nojvm?
You cannot use anything related to Java.

plus de 10 ans il y a | 0

| A accepté

Réponse apportée
Extrapolating a loop to a threshold
y = 2; threshold = 10; % sample threshold while y < threshold y = y^2 % sample calculation, put your function here...

plus de 10 ans il y a | 0

| A accepté

Réponse apportée
Splitting a vector into 'on' periods
I found a solution here: <http://stackoverflow.com/questions/27076618/how-to-split-vector-by-zeros-in-matlab> w = [false v~...

plus de 10 ans il y a | 0

Réponse apportée
Extracting data from a matrix
a = [1;88;37;6;75;3;7;43;30;45;954;24;87;63;24;12;0] a1 = a(1:4:end) a2 = a(2:4:end)

plus de 10 ans il y a | 1

| A accepté

Réponse apportée
Plot window appears at the end of the script. Why?
After the plot, use drawnow

plus de 10 ans il y a | 2

Réponse apportée
How to create and name several excel files in a loop?
Just create a new filename in each loop and write to this file: filename = sprintf('data%03d.xls', i);

plus de 10 ans il y a | 0

| A accepté

Réponse apportée
problem with regexp when multiple file in a folder
Returns the indices of cells in source_files.xlsx.name that contain the string 'Test Record' idx = find(not(cellfun(@isempt...

plus de 10 ans il y a | 0

Réponse apportée
How to cleanly display dates on X axis
You can try to reduce the FontSize

plus de 10 ans il y a | 0

Réponse apportée
gname for labelling lines in a plot
legend({'a', 'b', 'c', 'd'})

plus de 10 ans il y a | 0

Réponse apportée
How to implement the counter (really simple)?
You can write idx = ~(all(A > 0, 2) & all(B < 100, 2))

plus de 10 ans il y a | 0

Réponse apportée
Filter data into different Phases using multiple conditions.
The indices three positions after C is > 1 can be found using ind = find(C > 1) + 3; Ensure that the indices are not larg...

plus de 10 ans il y a | 0

Réponse apportée
How to divide a matrix by certain numbers?
A./repmat(v, 1, size(A, 2))

plus de 10 ans il y a | 0

Charger plus