Answered
How can I skip data while reading values from text file?
I try to use function fgetl as follows: Noticed that the first 2 rows have data format different from others, so they are remov...

4 years ago | 0

| accepted

Answered
Error Using cellfun for a Matrix
Try the following: for r = 1:27 for c = 1:27 A = a_d{r,c}; B_x{r,c} = cellfun(@(x) sum((x-A)./(x+A),'all...

4 years ago | 2

| accepted

Answered
How to make circle in matrix form
Another option using function pol2cart: clear; clc; separation = 1; % Angle separation, 1 degree ...

4 years ago | 0

Answered
I need to contour a round object in a image.
One possible way: rawdata = imread('Moon.jpeg'); BW1 = imbinarize(rawdata); BW2 = bwareafilt(BW1,1); BW3 = imfill(BW2,'holes...

4 years ago | 1

| accepted

Answered
How to set minorticks in colorbar?
Try the following: ax = axes('position',cb.Position); set(ax,'XMinorTick','on');

4 years ago | 0

Answered
How to list group names on resampled points after splitapply?
Try this: [G,name] = findgroups(holes12and13.holeid); % Store the extracted hold id % ...

4 years ago | 0

| accepted

Answered
text.png how to remove vertical lettering on a photo?
regionfill supports grayscale image and your input image is a black and white image only. Therefore, regionfill gives an error....

4 years ago | 0

| accepted

Answered
Daily mean of a hourly dataset
Try the following: filename = 'data_2001_2010.txt'; Data1 = readtable(filename,'VariableNamingRule','preserve'); Data1(:,1)=[...

4 years ago | 0

| accepted

Answered
Split table entry into separate columns
How about the following: Name = "ABBV 09/17/2021 120.00 C"; Data = "Dummy"; A = table(Name,Data); A.Name = strsplit(A.Name,...

4 years ago | 0

Answered
Overlay ROI on an image
The four-element position vector is located at roi.Position, which is [600,200,250,450], Try the following: pos=roi.Position; ...

4 years ago | 0

| accepted

Answered
determining the edges of the money image with red color
It is better to ask imfindcircles to find all the dark circles and adjust the range of radius. In your case, the range is too s...

4 years ago | 0

| accepted

Answered
How to adjust the intensity of grayscale image?
Use function imcontrast

4 years ago | 0

Answered
Plot line type not displaying as desired .
Try the following to sort the x-axis in correct order: figure(1) clf [sort_Id_A,idx] = sort(Id_A); sort_kf_max_SW_A = kf_max...

4 years ago | 1

| accepted

Answered
The angle and radius above the complex plane.
Something like this? rho = [1.5 1.3 1.0]; theta = [10 20 30]; Z = rho.*exp(deg2rad(theta).*1i); polarplot(Z,'*')

4 years ago | 0

| accepted

Answered
recieving error while using atand command
The value of variable 'aoa' is outside the interpolation range 'Aoa' and hence it gives NaN as the result. So the root cause is...

4 years ago | 0

| accepted

Answered
dropdown list cancel option
Try function isempty: if isempty(result) disp('User select to cancel'); end

4 years ago | 0

Answered
Plot a function for x<0 and x >0
You may modify based on the following code and you should plot first and then set the grid,title,xlabel,ylabel,etc x = -5:5; y...

4 years ago | 1

| accepted

Answered
derivative dot symbol in the legend of 2d plot
Somthing like the following? x = 1:10; y = 1:10; plot(x,y); legend('$\dot{\epsilon}$','Interpreter','latex','FontSize',16) ...

4 years ago | 0

| accepted

Answered
Matlab create function - Invalid expression
Simply modify your function as follows. function [relative_pose_endeffector] = forward_kinematics(T_0_3, q_actual) relati...

4 years ago | 0

| accepted

Answered
How to add the rows if it is same.
Put your data into a table with Variable Names 'Game' and 'Time', then use function groupsummary to sum up the values groupsum...

4 years ago | 0

| accepted

Answered
Cannot plot the full interval
You converted H_climb & H_cruise from [feet] to [m] by multiplying the value by 0.3048. However, there is no such conversion fo...

4 years ago | 1

| accepted

Answered
log2() only works with double types?
Check MATLAB documentation and this fucntion log2 supports type single or double as the input argument type.

4 years ago | 0

| accepted

Answered
y axis values - change the display
Modify the yticklabel as follows: % plot something ax = gca; yticklabels(arrayfun(@(x) sprintf('%d',x),ax.YTick,'uni',0))

4 years ago | 0

Answered
Using figure to change to fullscreen size then save it as png
Try the following for the figure you want to enlarge: fig1 = figure(1); fig1.WindowState = 'maximized';

4 years ago | 1

| accepted

Answered
Radially plot ROIs on image
Try using function cart2pol, following is an example clear; clc; Ny = 1000; Nx = 1000; Nz = 30; ...

4 years ago | 0

| accepted

Answered
What's the problem here?
function im2gray does not accept the jpg image, it accepts the image in pixel values Try the following: pic = imread('good_day...

4 years ago | 0

| accepted

Answered
Figure with 17x17 subplot
Another option is use function tiledlayout tiledlayout(17,17,'TileSpacing','none','Padding','none'); nexttile

4 years ago | 0

| accepted

Answered
How to read specific sheet from an excel file using readcell?
Try the following for an excel file name 'demo.xlsx', and sheet name 'Signals'. It is the same for readtable or readmatrix. re...

4 years ago | 1

| accepted

Answered
My frequency plot isn't showing anything
The idexing for frequency and residual torque, variable w and S starts from 1 to 1000 and from 2 to 11 resepctively. So I think...

4 years ago | 0

| accepted

Answered
Add '_max' to odd variable names and '_min' to even ones.
Suppose the table is called T, then try the following: T.Properties.VariableNames(1:4) = {'t_max','t_min','ang_azi_max','ang_az...

4 years ago | 0

Load more