已回答

trying to find which row this specific date time is at in an excel sheet

Presuming (although you didn't tell/show us) from the "dot" notation you used readtable to load the data into MATLAB, NumRows=h...

trying to find which row this specific date time is at in an excel sheet

Presuming (although you didn't tell/show us) from the "dot" notation you used readtable to load the data into MATLAB, NumRows=h...

17 days 前 | 1

已回答

I want to store the vector from each for-loop iteration, how can I do this?

You're almost there, you've just got to wrap your head around coding in "the MATLAB way"... nR=256; nC=256; % i...

I want to store the vector from each for-loop iteration, how can I do this?

You're almost there, you've just got to wrap your head around coding in "the MATLAB way"... nR=256; nC=256; % i...

17 days 前 | 1

| 已接受

已回答

I want to find the integration under the exported graph whose function is not known. How to do this?

" I have data points and after plotting the graph i need to find the area under it how do i do that?" <See example at> that is ...

I want to find the integration under the exported graph whose function is not known. How to do this?

" I have data points and after plotting the graph i need to find the area under it how do i do that?" <See example at> that is ...

17 days 前 | 0

已回答

How to plot a graph like this??

scatter it is, indeed. From the link, "specify x and y as matrices of equal size. In this case, scatter plots each column of y ...

How to plot a graph like this??

scatter it is, indeed. From the link, "specify x and y as matrices of equal size. In this case, scatter plots each column of y ...

18 days 前 | 0

| 已接受

已回答

Function "diff" and the loss of an element in the array

diff is defined as x(i+1)-x(i) for i=2:numel(x). But, MATLAB arrays are always 1-based so the result of x(2)-x(1) is in the fir...

Function "diff" and the loss of an element in the array

diff is defined as x(i+1)-x(i) for i=2:numel(x). But, MATLAB arrays are always 1-based so the result of x(2)-x(1) is in the fir...

18 days 前 | 0

已回答

how do I use importdata() to import specific columns of data from a .txt file?

importdata returns an array, not a struct nor table -- it has its uses, but I generally avoid it for more specific functions tha...

how do I use importdata() to import specific columns of data from a .txt file?

importdata returns an array, not a struct nor table -- it has its uses, but I generally avoid it for more specific functions tha...

18 days 前 | 0

已回答

Pass input arugments in .exe file generated by Matlab coder

<You must modify a main.c> function to read/use an argument list when creating a standalone executable; it doesn't happen by def...

Pass input arugments in .exe file generated by Matlab coder

<You must modify a main.c> function to read/use an argument list when creating a standalone executable; it doesn't happen by def...

20 days 前 | 0

| 已接受

已回答

readtable(html file) producing extra empty columns

Use 'SelectedVariableNames' with the variable(s) desired I can't tell what you want, specifically, there's a comment to read on...

readtable(html file) producing extra empty columns

Use 'SelectedVariableNames' with the variable(s) desired I can't tell what you want, specifically, there's a comment to read on...

21 days 前 | 0

已回答

How do I add these two variables? i keep on getting an error.

We don't know enough to be complete, but assuming the two input values are numeric, then function AddButtonPushed(app, event) ...

How do I add these two variables? i keep on getting an error.

We don't know enough to be complete, but assuming the two input values are numeric, then function AddButtonPushed(app, event) ...

22 days 前 | 0

已回答

Add zero padding to fft for accurate estimation

Returning the one-sided frequency spectrum instead of two-sided (the zero frequency/DC component is in the middle). Fs = 1e3; ...

Add zero padding to fft for accurate estimation

Returning the one-sided frequency spectrum instead of two-sided (the zero frequency/DC component is in the middle). Fs = 1e3; ...

25 days 前 | 0

已回答

How to set characters font in excel by m-file?

Worksheet.Range('A1').Characters('Start:=2, Length:=2').Font.ColorIndex = 3; % 2nd and 3rd characters color red, NG MATLAB does...

How to set characters font in excel by m-file?

Worksheet.Range('A1').Characters('Start:=2, Length:=2').Font.ColorIndex = 3; % 2nd and 3rd characters color red, NG MATLAB does...

25 days 前 | 0

| 已接受

已回答

Simple array multiplication of incompatible sized arrays

What KIND of "multiply"? "*" is matrix multiplication and SV=rand(62,3); NED=rand(186,3); M=NED*SV.'; whos M so you can mu...

Simple array multiplication of incompatible sized arrays

What KIND of "multiply"? "*" is matrix multiplication and SV=rand(62,3); NED=rand(186,3); M=NED*SV.'; whos M so you can mu...

26 days 前 | 1

| 已接受

已回答

Correlation and regression between matrixes with NaN values

"...regression and correlation coefficent between two matrixes (temperature and sea level pressure), ... to have a .... for ever...

Correlation and regression between matrixes with NaN values

"...regression and correlation coefficent between two matrixes (temperature and sea level pressure), ... to have a .... for ever...

26 days 前 | 2

已回答

Calculate values of struct of struct

The problem of using sequentially-named fields in the struct instead of an array of struct; there's no good way to process the r...

Calculate values of struct of struct

The problem of using sequentially-named fields in the struct instead of an array of struct; there's no good way to process the r...

27 days 前 | 1

已回答

Modify invalid field names in .mat file using code

unzip ExampleFile dir whos -file ExampleFile _* %S=load('ExampleFile') % _ADU_Odometer fid=fopen('ExampleFile.mat','r'); [f...

Modify invalid field names in .mat file using code

unzip ExampleFile dir whos -file ExampleFile _* %S=load('ExampleFile') % _ADU_Odometer fid=fopen('ExampleFile.mat','r'); [f...

28 days 前 | 0

已回答

Renaming files with the name of All subfolders

Undoubtedly this is the wrong-headed approach, don't use metadata inside the file names but create a database that contains the ...

Renaming files with the name of All subfolders

Undoubtedly this is the wrong-headed approach, don't use metadata inside the file names but create a database that contains the ...

28 days 前 | 0

已回答

How to repeat data because of variables with two different timestamps?

Illustrate -- t=seconds(0:1:300).'; % one-second time series arbitrar...

How to repeat data because of variables with two different timestamps?

Illustrate -- t=seconds(0:1:300).'; % one-second time series arbitrar...

29 days 前 | 0

| 已接受

已回答

How can I generate a legend of two combined figures? I

%um die diagonalen Beinpaare in eine Abbildung zu bekommen, inkl %Auftrittspunkte VR= openfig('bueVR150GZ.fig','invisible'); ...

How can I generate a legend of two combined figures? I

%um die diagonalen Beinpaare in eine Abbildung zu bekommen, inkl %Auftrittspunkte VR= openfig('bueVR150GZ.fig','invisible'); ...

29 days 前 | 0

| 已接受

已回答

How to transform a table to a matrix?

xlsread has been deprecated because it is more difficult to use with irregular data than the table. You can't put different dat...

How to transform a table to a matrix?

xlsread has been deprecated because it is more difficult to use with irregular data than the table. You can't put different dat...

1 month 前 | 1

| 已接受

已回答

Can I draw a section of a polar plot?

Well, sorta', but not totally generic. hPax=polaraxes('thetalim',[0 20],'thetazerolocation','top','thetadir','clockwise','rlim'...

Can I draw a section of a polar plot?

Well, sorta', but not totally generic. hPax=polaraxes('thetalim',[0 20],'thetazerolocation','top','thetadir','clockwise','rlim'...

1 month 前 | 0

| 已接受

已回答

iterating a function within itself

Several issues here... function [A1,B1,C1,D1,NPI_new,CPI_new] =CSS_iterate(fdrpath1,sheetname,RepCondpath) [A,B,C,D,NPI,CPI]=A...

iterating a function within itself

Several issues here... function [A1,B1,C1,D1,NPI_new,CPI_new] =CSS_iterate(fdrpath1,sheetname,RepCondpath) [A,B,C,D,NPI,CPI]=A...

1 month 前 | 0

已回答

Plot multiple variables from table with different x axes

There's also no need to loop; use the array inputs version of stairs D_indices=[1:3:width(map1)]; % would be all; limit...

Plot multiple variables from table with different x axes

There's also no need to loop; use the array inputs version of stairs D_indices=[1:3:width(map1)]; % would be all; limit...

1 month 前 | 1

已回答

Back calculating Ki from test data

You can only have N-1 differences. See diff for "the MATLAB way"... For a loop, you simply start with j=2 instead of 1; done w...

Back calculating Ki from test data

You can only have N-1 differences. See diff for "the MATLAB way"... For a loop, you simply start with j=2 instead of 1; done w...

1 month 前 | 0

| 已接受

已回答

How to fix "Failed to generate all binary outputs."

...WindowControlCoordination_SimulationAlgorithmModel.obj" "WindowControlCoordination_SimulationAlgorithmModel.c" In file incl...

How to fix "Failed to generate all binary outputs."

...WindowControlCoordination_SimulationAlgorithmModel.obj" "WindowControlCoordination_SimulationAlgorithmModel.c" In file incl...

1 month 前 | 0

| 已接受

已回答

How can I disable fminsearch function to print a warning message?

options = optimset('MaxIter',20); fun = @(x)100*(x(2) - x(1)^2)^2 + (1 - x(1))^2; x0 = [-1.2,1]; x = fminsearch(fun,x0,option...

How can I disable fminsearch function to print a warning message?

options = optimset('MaxIter',20); fun = @(x)100*(x(2) - x(1)^2)^2 + (1 - x(1))^2; x0 = [-1.2,1]; x = fminsearch(fun,x0,option...

1 month 前 | 2

已回答

New line after fprintf in a for/ while loop

Certainly the if...else...end clause itself has absolutely nothing to do with handling a newline in an fprint formatting string....

New line after fprintf in a for/ while loop

Certainly the if...else...end clause itself has absolutely nothing to do with handling a newline in an fprint formatting string....

1 month 前 | 0

已回答

Error using readtable (line 318) Matlab R2021a

t=readtable('sub_1.xlsx'); head(t) t=readtable('sub_1.xlsx','numheaderlines',0,'readvariablenames',1); head(t) Seems just fi...

Error using readtable (line 318) Matlab R2021a

t=readtable('sub_1.xlsx'); head(t) t=readtable('sub_1.xlsx','numheaderlines',0,'readvariablenames',1); head(t) Seems just fi...

1 month 前 | 0

已回答

how to type word to the legend left?

hL=plot(randn(10,2)); hLg=legend('Std','Avg'); %pos=hLg.Position; %pos(1)=pos(1)-0.1; %hA=annotation('textbox',pos,'String',...

how to type word to the legend left?

hL=plot(randn(10,2)); hLg=legend('Std','Avg'); %pos=hLg.Position; %pos(1)=pos(1)-0.1; %hA=annotation('textbox',pos,'String',...

1 month 前 | 2

| 已接受

已回答

semilogx() - x-axis - Increase scaling for lower frequencies - compress higher frequencies

The issue isn't the plotting scaling; it's the data content. Each of the triangular-looking traces in the reference plot goes f...

semilogx() - x-axis - Increase scaling for lower frequencies - compress higher frequencies

The issue isn't the plotting scaling; it's the data content. Each of the triangular-looking traces in the reference plot goes f...

1 month 前 | 0

| 已接受

已回答

How to resort every column of a 3d matrix?

L=-180:60:180 wrapTo360(L) [~,ix]=sort(ans) M=[1:3].*L.'; M=cat(3,M,2*M) M(ix,:,:) sortrows doesn't operate on 3D arrays s...

How to resort every column of a 3d matrix?

L=-180:60:180 wrapTo360(L) [~,ix]=sort(ans) M=[1:3].*L.'; M=cat(3,M,2*M) M(ix,:,:) sortrows doesn't operate on 3D arrays s...

1 month 前 | 0