回答済み
Boxplot using cell array where each cell has different size
Fill each cell with NaN to the same size vector and then convert to an array. boxplot will ignore the NaN missing value indicat...

約5年 前 | 2

| 採用済み

回答済み
Matrix to string, filled with zeros
>> string(num2str(A,'%04d')).' ans = 1×11 string array "9998" "9999" "0000" "0001" "0002" "9997" "99...

約5年 前 | 0

| 採用済み

回答済み
Multiple labels on xaxis
That's one way; I'd just rearrange the sizes/locations (position property) of the subplots to collapse the bottom two down so no...

約5年 前 | 1

回答済み
How to read in multiple text files, each containing multiple lines/formats?
Very difficult without example files to see the nuances, but the two records above I'd handle more like-- d=dir(fullfile('archi...

約5年 前 | 0

回答済み
Turn number to datetime
>> dtn=datetime(string(tn),'InputFormat','HHmmssSSS','Format','HHmmss.SSS') dtn = datetime 101416.517 >> NB: Howeve...

約5年 前 | 0

回答済み
Matlab2tikz, the tick labels of the x-axis in bold
[hAx,hLine1,hLine2] = plotyy(dataTime_s,pwm_ar_s,dataTime_f,deg_ar_f); linkaxes(hAx,'x') % link the two x...

約5年 前 | 1

| 採用済み

回答済み
Fill a timetable outside the gaps
Illustrate the concept -- tt.Var1=categorical(tt.Var1); % convert Var1 to categorical as rightfully is dRef=...

約5年 前 | 1

回答済み
Fill a timetable outside the gaps
K>> rowfun(@sum,t,"InputVariables",'Var2','GroupingVariables',{'Time','Var1'}) ans = 6×3 timetable Time Var1 ...

約5年 前 | 0

回答済み
randomly select elements of an array without repeat and create a matrix with these elements as rows
"1 to n. I want to choose m integers withiut replacement p times out of these integers, " What does the above mean, precisely? ...

約5年 前 | 0

| 採用済み

回答済み
How to speed up the following Matlab script? Can anyone suggest me to speed up the process?
Since you're doing all the work only to return coherence, look at doc mscohere to return the coherence directly with all the ...

約5年 前 | 1

| 採用済み

回答済み
[DISCONTINUED] MATLAB Answers Wish-list #5 (and bug reports)
At least w/ Firefox, recently the scroll wheel acts to reduce the size of the response textbox such that what is being typed get...

約5年 前 | 0

回答済み
Control decimal places of contour labels
Yet another case where TMW (The MathWorks) has been too aggressive in hiding stuff that clearly users would want to and should b...

約5年 前 | 1

| 採用済み

回答済み
How to read the specific colums from 12 excel files in a folder and then plot it
Other than superfluous stuff that doesn't need to be in the loop, nothing appears to be wrong in the basic code... Oh! Now I s...

約5年 前 | 1

| 採用済み

回答済み
Building a "Typical Year" from averaging daily-hourly data over several years
<AnsweredComment> OK, the conversation in the other thread turned into more interesting one than I initially anticipated; I tho...

約5年 前 | 1

| 採用済み

回答済み
How to read this kind of info out of a txt file and post them into Excel files?
Basically, just read the file record-by-record searching for the matching header strings and when find a section header, then re...

約5年 前 | 0

| 採用済み

回答済み
How to average monthly data using a specific method in Matlab?
There may be a more clever way, but brute force seems straightforward enough... A=reshape(vectorA,3,[]); ...

約5年 前 | 0

| 採用済み

回答済み
How to retrieve multiple values from a 3D array
Ignoring the excessively verbose variable names that keeps code from being visible without scrolling or breaking line and thereb...

約5年 前 | 0

| 採用済み

回答済み
Computing the number of variables belonging to each data type
How about n_cl=countcats(categorical(varfun(@class,M,'OutputFormat','cell')))

約5年 前 | 0

| 採用済み

回答済み
Can I plot a line function, and a plot function under an if statement?
"can put a line and plot function under an if statement. ...? It works when I try it ..." It would seem you've answered your ow...

約5年 前 | 0

| 採用済み

回答済み
Reading Specific numbers from a text file
fileID = fopen(filename); Cdata = textscan(fileID,'%f32 %f32 %f32','HeaderLines',5); % find the point coordi...

約5年 前 | 0

| 採用済み

回答済み
How to protect arbitrary variable names
Functions have their own workspace although internal and anonymous functions share their context with the containing workspace.....

約5年 前 | 0

| 採用済み

回答済み
displaying element of matrix
To use disp and have two decimal points, use format bank first, otherwise will get whatever precision is associated with the cur...

約5年 前 | 0

回答済み
How to plot 3 graphs in 1 figure?
There's an example of 2 on top and one on bottom that should have given the clue of how to bo about it... hAx(1)=subplot(2,2,1)...

約5年 前 | 1

| 採用済み

回答済み
Need to run two counters in a foor loop
If you describe the real problem to be solved instead, it'll lead to more efficient getting to the right answer, but if the resu...

約5年 前 | 0

回答済み
How can I find peak from matrix
What's wrong with what you've done for the one? findpeaks is one of the functions that has not been vectorized (owing to its co...

約5年 前 | 0

回答済み
Write a tabbed matrix in a txt file
Read the rest of the documentation for dlmwrite -- Name-Value Pair Arguments ... 'precision' — Numeric precision ...

約5年 前 | 0

| 採用済み

回答済み
Full Factorial Design of Experiments
"I know about the matlab function fullfact([,]) but since I will use decimal numbers i needed a differen solution." There's no ...

約5年 前 | 1

| 採用済み

回答済み
for loop to subtract every element from the first element for a given trial
Another job for varfun and grouping variables-- tt.TrialTime=cell2mat(rowfun(@(m)m-m(1),tt,'GroupingVariables','TrialNumber', ....

約5年 前 | 0

| 採用済み

回答済み
How do I make two arrays go from largest to smallest?
[a,ix] = sort([4 8 11 7],'descend'); % keep the optional original order vector when sort b = b(ix); ...

約5年 前 | 1

| 採用済み

回答済み
how to plot cell array and how to get its imaginary part?
Use cell indexing expressions-- >> c={[rand(4,1),rand(4,1)]}; % presume the format described for some sample data >> c{:} ...

約5年 前 | 0

| 採用済み

さらに読み込む