Answered
how can i change the color of the text in the dialog box of errordlg ?
Use the \color{specifier} modifier for the text string passed. Will have to create an options struct to set interpreter to 'Tex...

5 years ago | 0

| accepted

Answered
sorting is not sorting?!
sortrows(y,3); is a no-op because you didn't save the result. y=sortrows(y,3);

5 years ago | 0

| accepted

Answered
Add leading decimal places to numbers in text file
Air code--caution!!! c=readcell('YourTextFile.ext'); % bring file in as cellstr() array isDR=startsWith(c,'DataReg'); ...

5 years ago | 0

| accepted

Answered
Linking variable name/symbol to sequential retrieval of FRED data files.
"-the answer to your q is yes, this particular series are all on monthly freq and return the same dates." Ah! Was hoping for t...

5 years ago | 0

| accepted

Answered
how to create a chart with two x axes, one of which with month / day
Given you have 2019 in the variable names but won't give actual start/stop dates/times... x1=linspace(0,17508,17508) is a 17,5...

5 years ago | 0

Answered
how do i rearrage words in an alphabetical order in an array?
names =sort( split(' john alex peter matthew' )) names = 5×1 cell array {0×0 char } {'alex' } {'john' }...

5 years ago | 0

Answered
Output argument "x3" (and maybe others) not assigned during call to "threeptb"
I just worked through at command line -- >> fnK =@(x) (1.11 + 1.11*(x/10)^(-0.18))/(10-x); % the obj() function >> x1=1;...

5 years ago | 1

Answered
Changing file save name
Just add a counting variable that is incremented inside the inner loop-- ... j=0; for n = 1 : non_binary_images for k = 1 ...

5 years ago | 0

| accepted

Answered
How do I change position of titles and subtitles of subplots?
Try str=compose('Currents at %d mV ', [-70:10:0]); hposn={'left','right'}; figure for i=1:8 hAx(i)=subplot(4,2,i); hT...

5 years ago | 1

Answered
Append to vector of different sizes in for loop
The short answer is i = 1; A=[]; for i=1:2:numel(ipts) A = [A;TimeSeries_short(ipts(i):ipts(i+1),:); end Normally one fr...

5 years ago | 0

Answered
Two colormaps for same worldmap axis
You can only set one colormap for one graphic object with a colormap property -- colormap(target,colormap) ... target — T...

5 years ago | 0

Answered
how to generate let's say 1000 points in 2 dimensions uniformly distributed in the range xmin xmax ymin ymax
So what's wrong with rndxy=randi([5 30],100,10); ? Shape however wished; of course the dimensions have to be factors of N

5 years ago | 0

| accepted

Answered
Date axis in matlab heatplot
" I have converted the dates into number in excel and using those numbers to plot" Don't do that!!! Read the dates as datetime...

5 years ago | 0

| accepted

Answered
mutiplots in a single GUI figure
"...I need to plot all the three sets of data, I added hold off close the old plots on each new run..." That's exactly the wron...

5 years ago | 0

Answered
Declare a table where each column variable is an array of numbers
Your table entries must be cells, not arrays-- >> t=table({1:3}) % NB: the cell array is the quantity for the table t = ...

5 years ago | 0

Answered
Scatter of large dataset indexing figure name
N=size(A,2); for i=1:N for j=i+1:N figure scatter(A(:,i),A(:,j)) xlabel(string(i)) ylabel(string(j)) ...

5 years ago | 0

Answered
How to plot this graph
TMW has never seen fit to add the functionality to base 2D graphs for some reason -- fortunately, there's File Exchange https://...

5 years ago | 2

| accepted

Answered
How to generate a 10-bits digital signal which the 10 digits are “1753682094"
d=sscanf('1753682094','%1d'); ym=kron(d,ones(Ta/Ts,1)).';

5 years ago | 0

| accepted

Answered
Plotting scatter plot using X coordinate matrix and Y coordinate matrix
Don't need any loops X=x_coor(:); Y=y_coor(:); % vector; not required to plot, just to keep original data unchanged XLIM...

5 years ago | 1

| accepted

Answered
How to find the maximum and minimum value in the interval of a graph?
%load the file load('tokyoDart.mat'); %there are two column vectors: sampleTime and waterHeight %sampleTime is a datenumber ...

5 years ago | 0

| accepted

Answered
How to compare two arrays and add elements to the first one
You were on the right track... [LIA,LOCB]=ismember(A1(:,1),A2(:,1)); % find locations in respective arrays first column...

5 years ago | 0

| accepted

Answered
How to create separate tables from a data set
Boy! is that a mess! Why people/vendors do such things is beyond ken. Another start... G=readcell('Level Reduced.csv'); ...

5 years ago | 1

| accepted

Answered
Error using tabular/plot
Named parameters must follow X,Y,linespec triplets. plot(t,V,'r','LineWidth',3); instead. Or, alternatively, plot(t,V,'LineWi...

5 years ago | 0

Answered
How to perform a task on each 2D within a 3D array and get back the 3D at the end of it?
... non_uniform_FFT= DFTmtx* k2F;% This is a 2D array after each iteration. non_uniform_FFt= cat(3,non_uniform_FFT,non...

5 years ago | 0

| accepted

Answered
Importing date and time from a txt file
Add the first column datetime() and the second column duration(), or Read the file as fixed-width combining the first two colum...

5 years ago | 0

Answered
How to save an excel file to a specific path using ActiveX controls?
You don't give a fully-qualified filename; what else is it to do but use system default? [file,path]=uiputfile('.xlsx'); Workb...

5 years ago | 0

| accepted

Answered
How to combine stacked bar chart and line chart?
Seems to work fine here... figure hB=bar(step,array,'stacked'); ylim([0 16]) xlim(xlim+[1 -1]*500) yyaxis right hL=plot(st...

5 years ago | 0

| accepted

Answered
How to approximate value to values in an array
See doc interp1 with 'nearest' method.

5 years ago | 0

Answered
Match Xticks to Datapoints
x=[1 10 30 125 250 500]; plot(x,sort(randi(40,[6,1])),'*-') xticks(0:100:500) will duplicate the above with the addition of a...

5 years ago | 0

| accepted

Answered
Match Xticks to Datapoints
"with datetime, but then it is impossible to just display days and not specific dates." Au contraire, good buddy! tt=array2tim...

5 years ago | 0

Load more