Answered
How to remove the footstalks (shown in fig.A) of the leaf?
I'm a beginner, so I'm sure there is a better way. However, I managed to remove those lines in two simple steps using thresholdi...

7 years ago | 0

Answered
How to remove duplicate rows from .mat file or text file with out sorting?
Seems you are really close to finding the solution. out=unique(A,'rows','stable') should give you the unsorted unique ro...

7 years ago | 0

| accepted

Answered
How I can detect this ball in the image
For circles you can simply use the |imfindcircles| function. I=imread('crop.jpg'); imshow(I);hold on [centers rr] = i...

7 years ago | 1

| accepted

Answered
Find number of circles that intersect certain boundary?
You can use the function |inpolygon| to find points inside of the larger circle. Try adding the following lines of code after _t...

7 years ago | 0

| accepted

Answered
Title position below the x axis
Here are two options that may work for you: %alter vertical position of title figure;hold on subplot(2,1,1) ...

7 years ago | 1

Answered
Divide time array in day and night
There are many ways to do this. It is quite trivial in datetime format %This is your time vector time=datetime('2014-...

7 years ago | 1

Answered
how can I determine size of a text or csv file in matlab scripts?
props = dir(filename); props.bytes outputs the size of a file

7 years ago | 1

| accepted

Answered
Inserting a linear fit equation and R sq value for a scatter plot
The R^2 goodness of fit is stored in gof.rsquare. This is one way to display it in the plot together with the equation: ...

7 years ago | 0

| accepted

Answered
To Enter a Value in a Formulate
There are some different options. If you want to enter the value in the command window: T = input('Enter value of T') or...

7 years ago | 0

| accepted

Answered
How can i use transparency parametr in plot3 or other method to make my plot semi transparency
You can play around with some hidden marker properties. %get marker handles markers=w.MarkerHandle; %change tran...

7 years ago | 0

Answered
Re-gridding global data matrices onto a common grid in Matlab
You can resample your data using |griddedinterpolant|. It seems to ignore NaNs, which is good in this case. An example: ...

7 years ago | 1

| accepted

Answered
How to make bar graph come from the bottom for negative numbers
Modify the baseline ( <https://se.mathworks.com/help/matlab/creating_plots/modify-baseline-of-bar-graph.html link> )

7 years ago | 4

| accepted

Answered
How to make an animated stairstep graph?
You can use the |comet()| function if you manipulate the data a bit. x=[0:1:10]; a=[0 1 0 1 0 1 0 0 1 1 0]; xq=0:0.0...

7 years ago | 0

| accepted

Answered
detect increse/decreases in time series data
You can use the functions |findchangepts|, or |ischange| for time-series data, to detect abrupt changes in terms of slope or mea...

7 years ago | 0

| accepted

Answered
How to make a code that loads specific images from multiple subfolders within a single folder?
The documentation is great ( <https://se.mathworks.com/help/matlab/ref/addpath.html#btpdojp-1 link> ) search for 'Add Folder ...

7 years ago | 0

Answered
How to store the column names for each numerical values for respective rows in an array
You can try something like this. data=readtable('Name.xlsx','sheet','test') Headers=data.Properties.VariableNames(2:end)...

7 years ago | 1

| accepted

Answered
Plot air temperature data on pressure levels (Hovmöller diagram).
Here you go! Note that you specify the latitude and range of longitudes as the indices of their respective vectors, and not in u...

7 years ago | 3

| accepted

Answered
Load data from a table from another file
Sure, just specify the location before the filename, e.g.: readtable('H:\folder\Table.xlsx') you can also add the folder...

7 years ago | 1

| accepted

Answered
How to remove discontinuous edges of 3D surf plot?
Looks messy because log(0) is undefined. You can manipulate the data a bit and adjust the ZLim to make it look OK. Note that I a...

7 years ago | 0

| accepted

Answered
How can I fill in cells of a table with cells of another table while the two tables do not share the same number of rows?
Let's give it a try. I have created a working example with two excel files. This code finds the 'event' in Table2 associated wit...

7 years ago | 0

| accepted

Answered
How can I creat bar plots like the picture based on the existing data in attached Excel.
It's not the easiest figure to reproduce, as it involves double yaxis, errorbars and hatched fill. I have written a script for t...

7 years ago | 0

| accepted

Answered
2D image surf to 3D-plot
Perhaps you are trying to pass a color image to surf, which does not work. Note that if you load a grayscale image, it will stil...

7 years ago | 0

| accepted

Answered
Precision problem reading from excel?
You can actually reproduce this issue by typing: xlswrite('test15.xlsx',14.999999999999977) The cell in excel will say 1...

7 years ago | 0

Answered
datetime millisecond conversion puzzling
Problem: why does |milliseconds(X)| sometimes return doubles? Reason: Probably because the input value has decimals, in this...

7 years ago | 0

| accepted

Answered
loop in a column to calculate max and min in a certain interval
Perhaps this will help... data=readtable('ROSETTE_S2_R5_GeometricData.csv'); [volumes]=unique(data{:,1}); out=nan(2,l...

7 years ago | 0

Answered
how to plot latitude and longitude data on map??
The question is too vague. However, assuming you have the mapping toolbox, you probably want to use geoshow and/or geoplot.

7 years ago | 2

| accepted

Answered
How can I give color bar to my data in world map
I've never used |plotm|, but from the documentation it seems to be for 2D only, while what you want is 3D. You may wanna look in...

7 years ago | 0

| accepted

Answered
Replace values in each column by 0 after a pre-specified search value was found in that column
Here is one solution, [row,col]=find(A==0.5) A(min(row(col==1))+1:end,1)=0 A(min(row(col==2))+1:end,2)=0 it may re...

7 years ago | 0

Answered
how to compare rows of a matrix
You can use |unique()| to find unique rows |C| and their index [C,IA,IC] = unique(A,'rows')

7 years ago | 1

Load more