統計
All
Feeds
回答済み
table with NaNs into separate cells
% making a table with some all-NaN rows: Var = randi(100,12,4); Var([3 9],:) = NaN; M = array2table(Var) % split the table o...
table with NaNs into separate cells
% making a table with some all-NaN rows: Var = randi(100,12,4); Var([3 9],:) = NaN; M = array2table(Var) % split the table o...
約7時間 前 | 1
| 採用済み
回答済み
Reshaping a matrix based on the first row
Here's one way: A = [270 270 270 271 272 272 273 273 273]; B = [ 12 2 3 14 5 2 6 8 11]; [~,~,cidx] = unique(A...
Reshaping a matrix based on the first row
Here's one way: A = [270 270 270 271 272 272 273 273 273]; B = [ 12 2 3 14 5 2 6 8 11]; [~,~,cidx] = unique(A...
約7時間 前 | 0
回答済み
How do I change and save Check Box name in app designer so that it loads when I restart the app next time?
The main thing is that state has one field, which is "CheckBox", so it doesn't make sense to refer to state.InputEditField in lo...
How do I change and save Check Box name in app designer so that it loads when I restart the app next time?
The main thing is that state has one field, which is "CheckBox", so it doesn't make sense to refer to state.InputEditField in lo...
約11時間 前 | 1
| 採用済み
回答済み
How do variables work in Matlab App Designer?
"Does this mean that if I define variables in the function, I can't call upon those same variables in other parts of the code?" ...
How do variables work in Matlab App Designer?
"Does this mean that if I define variables in the function, I can't call upon those same variables in other parts of the code?" ...
約11時間 前 | 0
回答済み
Filled error bars to a plot
growth = readtable("growthWT2.xlsx"); time = growth.Time_h_; % no [ ] required timeOD = growth.Time_h__1; DO_1 = growth.O...
Filled error bars to a plot
growth = readtable("growthWT2.xlsx"); time = growth.Time_h_; % no [ ] required timeOD = growth.Time_h__1; DO_1 = growth.O...
約13時間 前 | 0
| 採用済み
回答済み
how to join two cell array
F = @(varargin)vertcat(varargin{:}); frameTOS = cellfun(F,frameTOS1,frameTOS2,'UniformOutput',false);
how to join two cell array
F = @(varargin)vertcat(varargin{:}); frameTOS = cellfun(F,frameTOS1,frameTOS2,'UniformOutput',false);
約14時間 前 | 1
回答済み
Plot a Cilinder or Sphere 3D
Still not sure what the matrix represents, but here is something: M = readmatrix('New Sphere 3D.txt'); angles = M(1,1:end-1); ...
Plot a Cilinder or Sphere 3D
Still not sure what the matrix represents, but here is something: M = readmatrix('New Sphere 3D.txt'); angles = M(1,1:end-1); ...
約15時間 前 | 0
| 採用済み
回答済み
Graph 3D Spheres
M = readmatrix('New Sphere 3D.txt'); angles = M(1,1:end-1); z = M(2:end,1); M(1,:) = []; M(:,1) = []; whos M z angles di...
Graph 3D Spheres
M = readmatrix('New Sphere 3D.txt'); angles = M(1,1:end-1); z = M(2:end,1); M(1,:) = []; M(:,1) = []; whos M z angles di...
約15時間 前 | 0
回答済み
Can you do the writeline function without the added terminator?
This documentation page: https://www.mathworks.com/help/instrument/serialport.configureterminator.html states that the "Allowe...
Can you do the writeline function without the added terminator?
This documentation page: https://www.mathworks.com/help/instrument/serialport.configureterminator.html states that the "Allowe...
1日 前 | 0
| 採用済み
回答済み
Vector Length Error when Calling Function
You have a variable called "length": length = data(2:end,2) Later, on this line: x_values1 = 1:length(PPI) the existence of ...
Vector Length Error when Calling Function
You have a variable called "length": length = data(2:end,2) Later, on this line: x_values1 = 1:length(PPI) the existence of ...
1日 前 | 0
回答済み
Find exact vector order in another vector array
If I understand correctly, you want to find where in a large vector (event_codes, size 1x19277) a small vector (e.g., att_event_...
Find exact vector order in another vector array
If I understand correctly, you want to find where in a large vector (event_codes, size 1x19277) a small vector (e.g., att_event_...
1日 前 | 0
| 採用済み
回答済み
3D scatter plot: can I make transparent points
"(or smaller)" You can specify the marker sizes: https://www.mathworks.com/help/matlab/ref/scatter3.html#mw_b556f712-aa82-4a50...
3D scatter plot: can I make transparent points
"(or smaller)" You can specify the marker sizes: https://www.mathworks.com/help/matlab/ref/scatter3.html#mw_b556f712-aa82-4a50...
1日 前 | 0
回答済み
I am having problems with GUI
Change the main BasicScreen function back to how it was (in particular, it appears you inadvertently removed the text "(varargin...
I am having problems with GUI
Change the main BasicScreen function back to how it was (in particular, it appears you inadvertently removed the text "(varargin...
1日 前 | 0
回答済み
Create contour plot from scatter plot
M = readmatrix('k.txt'); x = M(:,1); y = M(:,2); z = M(:,3); I = scatteredInterpolant(x,y,z); N = 80; X = linspace(min(x...
Create contour plot from scatter plot
M = readmatrix('k.txt'); x = M(:,1); y = M(:,2); z = M(:,3); I = scatteredInterpolant(x,y,z); N = 80; X = linspace(min(x...
1日 前 | 0
回答済み
Help with updating for loop
You can iterate backwards, so that subsequent indexing is never off the end of M. Example: M=[1 2 3 4 5 6 7 8 9 10]; for i=le...
Help with updating for loop
You can iterate backwards, so that subsequent indexing is never off the end of M. Example: M=[1 2 3 4 5 6 7 8 9 10]; for i=le...
2日 前 | 0
| 採用済み
回答済み
Plotting graph from.txt files and splitting their names
dir_files = '.'; F = dir(fullfile(dir_files,'*.txt')); colormatrix = [0.61,0.61,0.68; 0,1,1; 0,0,1]; mmatrix = ['o'; '*'; '+'...
Plotting graph from.txt files and splitting their names
dir_files = '.'; F = dir(fullfile(dir_files,'*.txt')); colormatrix = [0.61,0.61,0.68; 0,1,1; 0,0,1]; mmatrix = ['o'; '*'; '+'...
2日 前 | 0
回答済み
split up a matrix at discontinuities
A = [0 34.4; 60 33.3; 120 32.2; 180 31.1; 240 30; 300 28.9; 360 27.9; 420 26.8; 480 25.7; 540 24.7; 600 23.6; 660 22.6; 720 21.6...
split up a matrix at discontinuities
A = [0 34.4; 60 33.3; 120 32.2; 180 31.1; 240 30; 300 28.9; 360 27.9; 420 26.8; 480 25.7; 540 24.7; 600 23.6; 660 22.6; 720 21.6...
2日 前 | 1
| 採用済み
回答済み
Function with for loop doesn't always work
fclose the file, and you'll see it's not empty.
Function with for loop doesn't always work
fclose the file, and you'll see it's not empty.
3日 前 | 0
回答済み
Choose a random button from a set of 9 arranged in a 3x3?
Use this syntax: button_name = sprintf('Button_%d',n); app.(button_name).Text = num2str(Answer); Reference: https://www.mathw...
Choose a random button from a set of 9 arranged in a 3x3?
Use this syntax: button_name = sprintf('Button_%d',n); app.(button_name).Text = num2str(Answer); Reference: https://www.mathw...
4日 前 | 0
回答済み
How to "shake loose" an auto scaling graph when it doesn't autoscale?
Where ax is your uiaxes component: xlim(ax,'auto') ylim(ax,'auto') or, equivalently: ax.XLimMode = 'auto'; ax...
How to "shake loose" an auto scaling graph when it doesn't autoscale?
Where ax is your uiaxes component: xlim(ax,'auto') ylim(ax,'auto') or, equivalently: ax.XLimMode = 'auto'; ax...
4日 前 | 0
| 採用済み
回答済み
Output problem for If - statement in For - Loop
The difficulty, as you've found, is that to determine that the user's input does not match any of the answers, you have to check...
Output problem for If - statement in For - Loop
The difficulty, as you've found, is that to determine that the user's input does not match any of the answers, you have to check...
4日 前 | 0
| 採用済み
回答済み
How to get the y-axis in the foreground while having the grids in the background?
"I try to get the grids in the background behind jbfill and the yaxis/ yticks above the jbfill" That's no going to work; the g...
How to get the y-axis in the foreground while having the grids in the background?
"I try to get the grids in the background behind jbfill and the yaxis/ yticks above the jbfill" That's no going to work; the g...
4日 前 | 0
| 採用済み
回答済み
Unable to perform assignment because the left and right sides have a different number of elements.
The right side of this assignment is of size 100x1 T_update(2) = T(2) + (q_evap / (rho_water * Cp_water)); because q_evap is 1...
Unable to perform assignment because the left and right sides have a different number of elements.
The right side of this assignment is of size 100x1 T_update(2) = T(2) + (q_evap / (rho_water * Cp_water)); because q_evap is 1...
5日 前 | 0
| 採用済み
回答済み
3d matrix initialization and find the specific values after the for loops
You give A three columns when you do this: A=[m,n,p]; % size 1x3 Perhaps you meant: A=zeros([m,n,p]); But that w...
3d matrix initialization and find the specific values after the for loops
You give A three columns when you do this: A=[m,n,p]; % size 1x3 Perhaps you meant: A=zeros([m,n,p]); But that w...
5日 前 | 0
| 採用済み
回答済み
Readtable is not reading all of my Data
filename = fullfile('.', sprintf('SmartChipData_A%06i%s_Results.xlsx', 143881, 'B')); Specifying ExpectedNumVariables in detect...
Readtable is not reading all of my Data
filename = fullfile('.', sprintf('SmartChipData_A%06i%s_Results.xlsx', 143881, 'B')); Specifying ExpectedNumVariables in detect...
5日 前 | 0
| 採用済み
回答済み
Unable to perform assignment because the size of the left side is 1-by-1 and the size of the right side is 1-by-15. - can't find what the problem is
Assuming that b, m1, m2, n1, and n2 are scalars, the code runs ok. (Also assuming that the integers stored in the x, y, z variab...
Unable to perform assignment because the size of the left side is 1-by-1 and the size of the right side is 1-by-15. - can't find what the problem is
Assuming that b, m1, m2, n1, and n2 are scalars, the code runs ok. (Also assuming that the integers stored in the x, y, z variab...
5日 前 | 0
回答済み
Having issues writing matrix to a binary file.
I suspect there's something wrong with how you are reading the file. Here's an example of writing (using your code) and then re...
Having issues writing matrix to a binary file.
I suspect there's something wrong with how you are reading the file. Here's an example of writing (using your code) and then re...
5日 前 | 1
回答済み
copy subplots within same figure
To copy the legends, copy each with its associated axes (vector of objects to copyobj). To fix the overlapping, set the OuterPo...
copy subplots within same figure
To copy the legends, copy each with its associated axes (vector of objects to copyobj). To fix the overlapping, set the OuterPo...
5日 前 | 1
回答済み
uigetfile Multiselect option not working for single file select
You don't need separate scipts/functions. Since files is a cell array when multiple files were selected, and files is a charact...
uigetfile Multiselect option not working for single file select
You don't need separate scipts/functions. Since files is a cell array when multiple files were selected, and files is a charact...
5日 前 | 0
| 採用済み