Community Profile

photo

dpb


Last seen: Today
4,758 2012 年以降の合計貢献数

連絡する

dpb's バッジ

  • First Review
  • Master
  • Thankful Level 2
  • 36 Month Streak
  • Revival Level 1
  • Knowledgeable Level 4
  • First Answer
  • Solver

詳細を表示...

貢献した分野
表示方法

回答済み
Plotting a graph through the points
plot(x,y,'*-','LineWidth',2); b1=polyfit(x,y,1); y1=polyval(b1,[x(1),x(end)]); hold on plot([x(1),x(end)],y1,'r:'); b2=poly...

約13時間 前 | 0

| 採用済み

回答済み
finding peaks at specific indices/values
The actual bin frequency is unlikely to match the harmonics frequencies exactly (as in they won't match) so simply selecting the...

約15時間 前 | 0

回答済み
What data type is valid for piecewise functions?
syms x y = piecewise(x<0, -x, x>0, x); fplot(y,'r') axis([-10 10 -10 10])

約18時間 前 | 0

回答済み
how to replace multiple values per second with their standard deviaton?
Read the doc more carefully... TT2=retime(TT,'secondly',@std)

3日 前 | 0

| 採用済み

回答済み
I need to plot a Dynamic scattered plot. I have vector x and y, and those are coordinates. I need to plot coordinate 1, and then coordinate 2 but coordinate 1 must need to still there.
h = animatedline('Marker','none'); There's your problem... array=readmatrix('laser_data.csv'); % no point in a tab...

3日 前 | 0

| 採用済み

回答済み
How to search for header name and only pull that column as an array you can multiply
If you loaded the .csv into a table with headers that are variable names, you don't need to search nor "pull" data -- just refer...

4日 前 | 0

| 採用済み

回答済み
Plotting a figure with bars in stack
Any number of ways; a braind-dead sample y=sort(rand(20,2),1,'ascend'); % some dummy y data figure,hold on ...

5日 前 | 0

| 採用済み

回答済み
Particularly strange bug using the eval function
From the doc-- Whenever possible, do not include output arguments within the input to the eval function, such as eval(['outpu...

5日 前 | 2

回答済み
How do I erase string duplicates in one column of a cell array and add the strings' corresponding numbers in the second column?
>> c c = 6×2 cell array {'Sarah' } {[12]} {'Marie' } {[ 3]} {'Sam' } {[ 5]} {'Rose' } {[ ...

6日 前 | 1

回答済み
Why do my FFTs look wildly different?
Above just based on the figures; reading the m file reveals a major problem -- you only processed the first N = 1024 points of ...

6日 前 | 0

回答済み
Error: File: t2_m1.m Line: 46 Column: 8 The input character is not valid in MATLAB statements or expressions.
Unrecognized function or variable 'material_1'. >> material_1=rand(10,120); >> x = (2:2:120); c_1 = material_1(:, x); vf_1 ...

7日 前 | 0

| 採用済み

回答済み
Plotting several .txt files
... fullFileName = fullfile(theFiles(k).folder, baseFileName); fprintf(1, 'Now reading %s\n', fullFileName); plot(fullFileNam...

7日 前 | 0

| 採用済み

回答済み
Matrix addition in a loop in a random column
Must reference the same size section of array on LHS of an assignment as the RHS unless assign the entire LHS variable to RHS. ...

7日 前 | 0

回答済み
Carry trade portfolio with 20 countries
That was kinda' fun!!! :) % create some sample data...use a table for convenience tPort=[ table(datetime(1997,0:20,1,'For...

8日 前 | 0

回答済み
Creating a built in function?
Don't put it on the Desktop, create a folder in your user area for MATLAB and then add that folder to the MATLABPATH and make pe...

9日 前 | 1

| 採用済み

回答済み
How do you get multiple minimum values in a column based on grouping and then isolate the corresponding rows for the whole table?
[g,ig]=findgroups(data.names); b=splitapply(@(x) {maxk(x,10)},data.age,g); b contains the k oldest elements for each group...y...

10日 前 | 0

| 採用済み

回答済み
peak in fixed interval in findpeaks
There simply isn't much in the way of a peak to find -- I can't discern enough even by eye to count to eleven in that trace... ...

10日 前 | 0

| 採用済み

回答済み
Reduce the distance between boxplots
Carrying on from the above idea... data=rand(10,16); % just some random data w/ 16 variables/columns data2=[]; for i=...

10日 前 | 1

| 採用済み

回答済み
How to label Y axes in place of column1 column 2 etc
YT=cellstr(datetime(2020,1:12,1,'Format','MMMyy')); % cellstr array of MMMyy hSP=stackedplot(YT.','DisplayLabels',YT); ...

11日 前 | 0

回答済み
Is it possible to write the function (mathematical formula) of a custom probability distribution from data?
To generate a functional form totally independently from only a dataset is pretty much not feasible. There are a number of gene...

11日 前 | 0

回答済み
Draw a colored error map based on the measurement error
More than one way to skin a cat... :) hHM=heatmap(reshape(RMSE,6,6)); % draw the heatmap; fixup some to draw on top...

11日 前 | 1

| 採用済み

回答済み
How to sort a table (only 2 rows)
[~,imin]=min(T.value); [~,imax]=max(T.value); T=[T(imin,:); T; T(imax,:)]; T([imin,imax],:)=[]; Or, save the two rows of int...

11日 前 | 0

回答済み
How to load multiple files sequentially with no standard extension into MATLAB at once
If you place them all in a clean directory, then d=dir(fullfile('TheBearingDataSetDirectory','*.*')); will return all in a dir...

12日 前 | 0

回答済み
How can i set legend for different bar with different colors?
As per usual (despite some much-needed belated improvements on at least being able to label a bar, thanks! TMW) bar is still a r...

13日 前 | 0

回答済み
Combine three columns with comma for a lot CSV files
fileDir = 'D:\Examps'; d=dir(fullfile(fileDir,'*.csv'); for i = 1:numel(d) data=readmatrix(fullfile(fileDir,d(i).name),'Num...

14日 前 | 0

| 採用済み

回答済み
MATLAB Answers Wish-list #5 (and bug reports)
Who's idea to introduce the black background for code? I can read almost nothing now easily with the small contrast between the...

15日 前 | 0

回答済み
Error with Uniquetol: " Repetitive numbers not being removed"
Yeah, fix the magnitude of the tolerance interval you want distinguished--by default uniquetol(A) uses 1e-6 for single-precision...

19日 前 | 0

回答済み
Find indices of elements for given difference
find and/or ismember will only return EXACT matches -- will NOT return something "on or about" a 10 ms interval. Two possibilit...

19日 前 | 0

回答済み
How to save multiple matrix in a .dat file
DON'T EVEN THINK OF IT!!! From the documentation... Use one of the text formats to save MATLAB numeric values to text files. I...

19日 前 | 0

回答済み
can meaning of ~= be "equal to" ?
Since MATLAB array counting is 1-based, have to move up by one from the 0-based counting. The solution produces the expected re...

21日 前 | 0

Load more