回答済み
How to write the results of createFit to a csv or txt file
Replace this: X = [xData(:), yData(:), zData(:)]; [~,F,~] = fileparts(X); with this: X = [xData(:), yData(:), fitresult(xDat...

2年以上 前 | 0

| 採用済み

回答済み
How to get heat maps (color the surface) in Matlab?
T = readtable('heat_map.xlsx','VariableNamingRule','preserve') nX = numel(unique(T.(1))); nY = numel(unique(T.(2))); X = resh...

2年以上 前 | 1

| 採用済み

回答済み
Why is my errorbar legend not showing the proper colors?
errorbar(x,y,err), with vector x and y and scalar err, produces as many errorbar objects as there are elements in x (or y). In ...

2年以上 前 | 0

回答済み
PolarPlot Axes Shape Change
% data: th = deg2rad(50:10:140); r1 = 70+20*rand(size(th)); r2 = 50+20*rand(size(th)); % polaraxes setup: f = figure('Col...

2年以上 前 | 0

| 採用済み

回答済み
How do I get rid of grid lines on a surface plot?
Use 'EdgeColor','none' or 'LineStyle','none' z = peaks(100); figure surface(z) % with grids figure surface(z,'EdgeColor','n...

2年以上 前 | 0

回答済み
Unit vector from the vector
Put the components in a vector: mean_U0_vector = [mean_speed_R, mean_speed_T, mean_speed_N]; % u_0 vector Then the unit vector...

2年以上 前 | 0

| 採用済み

回答済み
How can I get the quiver arrows to 'line up'?
For the first question: Part of the reason for the quiver arrows being scattered is that the U and V calculation is incorrect. ...

2年以上 前 | 0

| 採用済み

回答済み
Are the rules for element by element matrix operation changed?
Yes, this behavior changed in R2016b. See: https://blogs.mathworks.com/loren/2016/10/24/matlab-arithmetic-expands-in-r2016b/

2年以上 前 | 0

| 採用済み

回答済み
Problems overlaying contour on image in uifigure
Use hold(a2,'all') That is, you need to specify the axes you want to hold.

2年以上 前 | 1

| 採用済み

回答済み
Applying time axis limits to plots in UTC time
Here's an example of setting the axes x-limits using duration values: x = duration(1,1:30,0) % duration x y = rand(size(x)); %...

2年以上 前 | 1

| 採用済み

回答済み
Deleting certain rows with partially duplicate values
I'll assume that's a table and the text entries are strings. T = table( ... [1;1;3;6;2;2], ... ["March-1st";"March-1s...

2年以上 前 | 0

回答済み
How can I put a number that changes according to how many times the question has been asked in a menu?
X = zeros(1,7); for i=1:7 X(i)=menu(sprintf("Did you feel good on day %d?",i),"Yes","No"); if X(i)==2 X(i)=0...

2年以上 前 | 1

| 採用済み

回答済み
I wanted to combine 100 csv files for plotting in Matlab. All the files have same number of columns and rows. Can anyone help?
your_folder = 'folder where the csv files are'; % absolute or relative path csvFiles = dir(fullfile(your_folder,'*.csv')) ; na...

2年以上 前 | 1

| 採用済み

回答済み
hi , i want to build a system that can calcuate the arc length where user can insert the equation, limit a and b . But i got an error, i dont know how to solve the error.
Use str2sym, like the error message says. The expression entered has to be valid MATLAB syntax or it's not going to work (e.g.,...

2年以上 前 | 1

回答済み
Creating an inset figure from an other fig file
% open the first figure fig1 = openfig('figure1.fig','visible'); % create the new axes ax2 = axes(fig1,'Units','normalized'...

2年以上 前 | 0

| 採用済み

回答済み
Start date and end date uipicker = Having issue to plot it on UI Axes using excel data of particular selected start and end date
Please see the modified app attached. In keeping with the existing design where the plot is updated when the Generate Plot butt...

2年以上 前 | 0

| 採用済み

回答済み
conversion depth to time
velocities_data has only one row, so don't index velocities_m_per_s with i in the inner loop: %================================...

2年以上 前 | 0

| 採用済み

回答済み
How can i restrict the cross cursor in ginput function into a specific UIAxes instead of it showing in the whole appdesigner figure?
You can modify ginput to do that. First make a copy of ginput.m, put it in your current folder and rename it to something like ...

2年以上 前 | 0

| 採用済み

回答済み
How can I decrease the runtime for a function (using cellfun or parfor)?
Before worrying about cellfun vs parfor to call the function, try to make the function itself more efficient. Compare the funct...

2年以上 前 | 0

| 採用済み

回答済み
Plot with shaded standard deviation
It looks like your y_values_upper and y_values_lower are column vectors, so be sure to take that into account when creating the ...

2年以上 前 | 0

| 採用済み

回答済み
Line Width and Style Will Not Change
Set the line width and style in the plot call, not the title call. t = 1:10; p = 2:11; plot(t,p,'LineWidth',5,'LineStyle','...

2年以上 前 | 0

| 採用済み

回答済み
How to plot this colormap correctly?
The difference between adjacent elements of depths is not constant. (Same for time.) load depth load temp load time % diff...

2年以上 前 | 0

| 採用済み

回答済み
How to revolve a polar contour plot of scalar to obtain sphere contours?
Extending your idea a little bit by specifying the FaceColor of each surface: r = 0.1:0.1:1; Nr = numel(r); cmap = flipud(par...

2年以上 前 | 0

回答済み
How to get larger font size for inputdlg, MATLAB ver 2019a
The Accepted Answer in the thread you linked to actually contains all the information you need. The only thing I would clarify ...

2年以上 前 | 0

回答済み
Error of Ploting the contour that satisfies a condition
Does using NaN instead of 0 give the desired result? See below. clear all close all clc Vo_max = 400; Pout = 1000; fs ...

2年以上 前 | 1

| 採用済み

回答済み
Filtering data from interpolated points on patch
xy = [1 3.1 2.6 2.8 1.3 1.9 2.8 1.5 3.7 2.1 2 0.9]; Connectivity_matrix = [3 2 1 ...

2年以上 前 | 0

| 採用済み

回答済み
How to create a better 3D Discrete Plot?
Maybe a surface? Something like this: % Parameters numBases = 100; % Number of base pairs kappa = 0.1; % Elasticity constant ...

2年以上 前 | 1

| 採用済み

回答済み
Trying to extract rows of a matrix where a given column equals a range of values
X = load('enlistcell_new_YFP_WithmCherry.mat').enlistcell_new_YFP_WithmCherry "2nd column ... equals a range of values (i.e., 3...

2年以上 前 | 0

| 採用済み

回答済み
multiple actions following @(src,event) in uicontrol
Define a function that has whatever code in it you want. Then make that function the button's callback: Button=uicontrol...

2年以上 前 | 0

| 採用済み

回答済み
bar graph color and error
x = [1,2,3,4,5]; y = [5.03E-11 5.35E-11 4.55E-11 8.85E-11 6.26E-11; 5.03E-11 5.35E-11 4.58E-11 8.95E-11 6.26E-11; 3.7...

2年以上 前 | 1

| 採用済み

さらに読み込む