Community Profile

photo

jonas


61 total contributions since 2018

Contact

jonas's Badges

  • Knowledgeable Level 3
  • 3 Month Streak
  • First Answer

View details...

Contributions in
View by

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> )

8 days ago | 2

| 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...

9 days 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...

9 days 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 ...

10 days 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)...

16 days 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...

19 days ago | 1

| 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...

20 days 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...

20 days 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...

20 days 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...

21 days 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...

21 days 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...

25 days 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...

25 days 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...

26 days 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(Lon,Lat)

26 days ago | 0

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...

26 days 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...

26 days 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')

26 days ago | 1

Answered
Converting GPS time to Local Time
t2=datestr(seconds(t)+hours(12),'HH:MM')

27 days ago | 0

| accepted

Answered
Adding legend for iteration and if condition graph
Try this, title('Graph of behaviour against iteration'); xlabel('iteration t'); ylabel('beha...

28 days ago | 0

Answered
Details on surf plot
As an alternative to waterfall, I just learned that you can change the meshstyle of surfaces h=surf(peaks) h.MeshStyle='...

28 days ago | 1

| accepted

Answered
The sum of the loop elements
First of all you need to store the values of fi_z_i in every iteration, so that you end up with a vector consisting of all latit...

29 days ago | 1

| accepted

Answered
how to fill in zeros in index not used?
Not sure I understand the question, but... B=zeros(1,3); %Case 1 B(2)=5 %Case 2 B(1)=5

29 days ago | 0

Answered
Map axis description (degrees).
It is easier than you think, try this landareas=shaperead('landareas.shp','UseGeoCoords',true); axesm ('mercator','Frame...

29 days ago | 1

| accepted

Answered
I need to plot around 60 graphs, i wrote the following code but the graphs are too small to see them easily, how could I plot them bigger than now?
Plotting 60 graphs in a single window will make each axes small. Your options are to increase the size of the figure set(gc...

29 days ago | 0

Answered
Plot in log-log
I'm fairly sure that is in fact a loglog-scale. Try: axis([0.1 100 0.1 100]) and see for yourself. The y-range is too na...

30 days ago | 0

| accepted

Answered
hi every body.my question is how can i plot subplot like this picture in Matlab. i want draw dotted line cross the subplots like red dotted line and write on it like blue circle.
(1) learn how to use subplots MATLAB has a function |subplots()| which is really easy to use. Personally I prefer the functio...

30 days ago | 1

| accepted

Answered
Change the name of a figure in a Correlation plot
Just set the name of your figure by set(gcf,'Name','string')

30 days ago | 0

| accepted

Answered
How could i search a text for varying patterns
Not sure if it's the best way, but the code starts at str(5) and ends at the dash, so this should work [~,s] = regexp(str, ...

1 month ago | 1

Load more