回答済み
Help ! Excel import to Matlab
That's an Excel question (or at least approach to the question) rather than Matlab. You'd have to use a lookup function in Exce...

10年弱 前 | 0

回答済み
How to subtract a surface equation from a surface 'scatter plot'?
Simple. dZ=zvalue-Test(xvalue,yvalue); Just evaluate the equation at the existing points and compute the difference. ...

10年弱 前 | 0

| 採用済み

回答済み
How can I put index number of matrix itself?
Use a cell array; look them up for examples and syntax; you use the "curlies" {} instead of () to create a cell reference and to...

10年弱 前 | 0

回答済み
I need to create a text file using numeric data (a basic 4x4 matrix). (I'm very new to this)
dlmwrite('mydata.txt', [10 5 7 9; 11 8 0 5; 17 34 67 89; 87 54 32 98], '\t'); mydata=load('mydata.txt'); Or, unless ther...

10年弱 前 | 0

| 採用済み

回答済み
How to set different part of a line with differnet color?
Have to draw three lines; the color property is a single value for each line object. Also then note that to have continuous lin...

10年弱 前 | 0

回答済み
Why does it give me a wrong answer when I want to find the absolute minumum of the function g(t)?
*More About* "fminbnd is a function file. Its algorithm is based on golden section search and parabolic interpolation. Unle...

10年弱 前 | 0

回答済み
Exporting numerical and string values to *.txt file (in batch)
Making this way harder than needs be... fmtOut = [repmat('%6d\t',1,2) repmat('%6.2f\t',1,3) '%s\n']; % Batch Processing ...

10年弱 前 | 1

| 採用済み

回答済み
Removing strings or NaNs from data to be plotted
Well, ideas would depend upon what you want -- *plot* and friends will gladly handle NaN; they even show where they are located ...

10年弱 前 | 1

| 採用済み

回答済み
How can I read 3 sensor values separated by hex values in unformatted text file using matlab and convert sensor values to decimal
>> data=sscanf(buf,'%2X'); >> reshape(data(1:end-1),2,[]).' ans = 36 184 3 206 2 203 ...

10年弱 前 | 0

| 採用済み

回答済み
How to scale the frequency axis after performing fft?
Plot versus frequency instead of samples...the dominant frequency won't _necessarily_ be in the same place but it'll show up at ...

10年弱 前 | 1

| 採用済み

回答済み
Multiple x axes with datetime time series
It's not hard to create the second axes object; see the example under _Graphics Objects_ on _Using Mulitple X- and Y-Axes_ Th...

10年弱 前 | 0

回答済み
finding some specific numbers in a numeric cell array
Looks like you've nested the cell array; either create an array of cells with the double arrays each per cell or dereference ins...

10年弱 前 | 0

| 採用済み

回答済み
How to just select the date in a date-time excel upload.
Use *yyyymmdd* instead...

10年弱 前 | 0

回答済み
fprintf file timestamp to csv
_fid_ isn't good variable name for a directory list; too much associated with a file handle. d=dir('*.txt'); ...

10年弱 前 | 0

| 採用済み

回答済み
Two signals with different x-values. Mean(..)
If you can plot them, then I presume you have them as variables. Since the x-values appear to be nonconformant in magnitude, ab...

10年弱 前 | 0

回答済み
If the value from the 1st column in one matrix is between two 1st column values from another matrix, return the row values from the second matrix.
weights=cell2mat(arrayfun(@(x) Weight_Latbin(find(x>Weight_Latbin(:,1),1,'last'),2:end),rawdata,'uniform',false)) weights = ...

10年弱 前 | 0

| 採用済み

回答済み
Help creating variable list listing all combinations for DOE
Think you'll have to build some corollary data... >> vars={'CUBIC PER ATR';'RSI';'STOCHASTIC K'}; % the list of variables ...

10年弱 前 | 1

| 採用済み

回答済み
How to string 1 and 0 into array
More generic for the numeric conversion is sscanf('1101111000111101','%1d') as can set the field width; the subtraction ...

10年弱 前 | 1

回答済み
Hi, i want to count how many time the same number repeat itself in a vector, and i want to report these numbers in another vector
> v= sscanf('11454144545','%1d'); % convert to numeric array >> r=histc(v,unique(v)) r = 3 5 3 ...

10年弱 前 | 0

回答済み
Extracting numbers from a text file
Presuming the asterisks aren't actually in the file, fid=fopen('Results.txt','rt'); %open the file data=cell2mat(textsca...

10年弱 前 | 1

回答済み
How can I remove NaN values from a 7862x6 cell?
Presuming can decipher the actual storage you're trying to describe, here's a sample and solution to the number... >> A=n...

10年弱 前 | 0

| 採用済み

回答済み
How to show values used in min() function?
[mnCost mnIdx]=min(cost); >> sprintf('Min R,L,cost: %.2f,%.4f = %.2f',R(mnIdx),L(mnIdx),mnCost) ans = Min R,L,cost: 15.55...

10年弱 前 | 0

回答済み
sort a matrix of size m x 3 with respect to column 2 and then column 1 -
sortedData=sortrows(data([2 1]); % doc sortrows for details

10年弱 前 | 1

| 採用済み

回答済み
Importing matlab data in a loop using keywords from a cell
>> c1=char(a1);c2=char(a2); >> list=a1(ismember(c1(:,1:3),c2(:,1:3),'rows')) list = 'K01 mainEEG.mat' 'K02 mainEEG....

10年弱 前 | 0

回答済み
How can I remove left y-axis tick marks from the right y-axis, AND retain the top x-axis with MatLab 2015a?
x=[1:100].';y=randn(100,1); % some dummy data to plot to make axes w/ differing ranges hAx=plotyy(x,y,x,sqrt(abs(y))/pi); ...

10年弱 前 | 0

回答済み
plotting multiple plots in matlab
Plot the raw signal first, _then_ call *hold on*, _then_ add the other plots to the base. If you'll compute all the results fir...

10年弱 前 | 0

回答済み
Loop through data until date changes
Use *unique* to find the set of dates in Bonds.Settle then *accumarray* to process and accumulate results over those by set.

10年弱 前 | 0

回答済み
To accept two numbers and display the number of perfect numbers within the range
A) Don't use *sum* as a variable; it aliases the builtin Matlab function of the same name. This won't hurt you in the present c...

10年弱 前 | 0

回答済み
Geting a Unexpected MATLAB expression , for my function but works fine on the console
function w=flip_it(v) I'm more than surprised there's no flag in the editor and/or that it could run as is w/o the missing ...

10年弱 前 | 0

回答済み
How do I include a variable when trying to display a string?
Use the optional output format startHW1=datetime('now','Format','dd-MMM-yyyy HH:mm:ss'); disp(['I started HW1 on ' start...

10年弱 前 | 0

| 採用済み

さらに読み込む