Réponse apportée
How to supplement the matrix?
Adding to Stephen's answer Matlab syntax, the crystal ball says for i = 1:length(d)-1 % Error 1100 1099 if g(i)-50>= g(i...

environ 7 ans il y a | 0

Réponse apportée
How can I merge a numeric matrix (1 column) to an existing numeric matrix?
Presuming the B vector already exists to match the right size, simply knowing the row number is sufficient... B(sc:end,2)=A;

environ 7 ans il y a | 0

| A accepté

Réponse apportée
plot with two datetick axis
Don't use datenum and datetick, use datetime instead for which plot has builtin support. You should be able to create two indep...

environ 7 ans il y a | 0

Réponse apportée
Pairwise difference of datetime vectors (i.e. pdist for time data)
Presuming not excessive precision, one could convert to datenum, compute distances and then return to datetime Seems like a fea...

environ 7 ans il y a | 1

Réponse apportée
Can I use Matlab to read in data that's in an unusual layout
A little tedious to set up, but easily-enough handled for a regular file format such as this. First you have to either know the...

environ 7 ans il y a | 1

| A accepté

Réponse apportée
What are the methods and corresponding functions in matlab to fill missing data temporally in rainfall timeseries?
Well, time-based was understood the point of the Q? was whether you were also requesting some specific and recognized in the fie...

environ 7 ans il y a | 0

Réponse apportée
Find column with error and delete it
isStr=find(cellfun(@isstr,table2cell(dataFromTable(1,:)))); if(cell2mat(strfind(dataFromTable{1,isStr},'$$ER'))) dataFromTab...

environ 7 ans il y a | 0

Réponse apportée
What data points does interp1 use for linear interpolation?
inter1 does linear interpolation between points unless you use 'nearest'|'next''|'previous' for the method. It also requires th...

environ 7 ans il y a | 0

Réponse apportée
Help!!! how to search for some xx xx xx xx(hex) in a dat file very fast!!!
If it's performance you're looking for, pass the job off to a grep utility...there are any number of freeware versions available...

environ 7 ans il y a | 0

Réponse apportée
Convert String Array to Numeric matrix and string array
EventVals=str2double(data_events(1:2:end,:)); EventCmnt=data_events(2,:);

environ 7 ans il y a | 1

Réponse apportée
Stacked bar graph with secondary y-axis line graph
[~,~,r]=xlsread('MLQ.xlsx'); % just read the spreadsheet to see what was in it... MLQopt=detectImportOptions('MLQ....

environ 7 ans il y a | 0

| A accepté

Réponse apportée
How to access names of external drive from path?
That's an OS command -- on Windows there's "VOL" >> !vol Volume in drive C is OS Volume Serial Number is ... >>

environ 7 ans il y a | 0

| A accepté

Réponse apportée
fread() help. "Error using fread: Invalid file identifier..."
[filename, pathname]=uigetfile('*.ptu', 'T-Mode data:'); %Opens dialog box to manually select the file using file explorer ...

environ 7 ans il y a | 1

| A accepté

Réponse apportée
Customizing MATLAB Plots and Subplots
The new(ish) yyaxis function to arbitrarily create two y axes and then switch between left and right axes w/o the need of yyplot...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Select specific data from txt file
Just read the file into memory and do a find() -- since it's an integer that'll be exact. What do you do if there isn't a matc...

environ 7 ans il y a | 0

Réponse apportée
What Is A Scalar String?
A scalar string is simply a string that is not an array of strings...see https://www.mathworks.com/help/fixedpoint/ug/code-gener...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
for loops not working
"The MATLAB way" is to avoid the loops altogether... N=10; M=1000; [X,Y]=meshgrid([1:N],1:M]); func=(X*pi/Lx).^2 +(Y*pi/Lz).^...

environ 7 ans il y a | 0

Réponse apportée
How can I shift the elements in a vector without losing the elements? just shift the order
Sorta' inconsistent definition, but look at >> A=1:10; >> circshift(A(4:end-2),-2) % case 1 ans = 6 7 ...

environ 7 ans il y a | 0

Réponse apportée
How to transform an array into a bottom triangle
On the above assumption, if V is the vector, then N=149; % array size parameter R=V(cumsum([N:-1:1])); ...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Finding elements of an arrays having specified index numbers
Given you return the indices in vectors ix and iy, then V=A(sub2ind(size(A),ix,iy)); where A is the other array and V will be ...

environ 7 ans il y a | 2

| A accepté

Réponse apportée
Use the index of an element of a subset to find its index in the large set?
tipPt=[2 3 2]; % the two located points smpPt=[2 3 1]; % return their locations in the two arrays, respectively ...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
vertical error bar in loglog plot
hEB=errorbar(x,A,err); hAx=gca; hAx.XScale='log'; hAx.YScale='log'; You'll have to have defined the error magnitude array, e...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Having multiple lines in a character array for column labels in a heatmap
Unless TMW has finally fixed it, the TickLabel interpreter is pretty brain dead...you can do something like ColumnLabels=strrep...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Replace categorical value with numeric values
If categorical variable is c, then d=double(c)-1; presuming didn't define them except by default which will be in alphanumeric...

environ 7 ans il y a | 0

Réponse apportée
i need to compare a matrix with a static table
> [interp1(Y(:,1),Y(:,2),X(:,1)) interp1(Z(:,1),Z(:,2),X(:,2)) interp1(A(:,1),A(:,2),X(:,3))] ans = 279.6900 255.4500 247....

environ 7 ans il y a | 0

| A accepté

Réponse apportée
msgbox is not displaying the string entered in body
Should be msgbox('Message','Title')

environ 7 ans il y a | 0

Réponse apportée
Generate beta random number without statistics toolbox
Given Ui are uniform random variates Y1=U1/α1 and Y2=U1/β1, such that Y1+Y2<=1, then X=Y1/(Y1+Y2) follows the beta dist...

environ 7 ans il y a | 0

Charger plus