Réponse apportée

Matlab coding for equation below and output as matrix

Hi, Look at this piecewise function definition: piecewise

Matlab coding for equation below and output as matrix

Hi, Look at this piecewise function definition: piecewise

presque 5 ans il y a | 0

Réponse apportée

How to find an exact sequence of values?

Try Loren's findpattern2. Here is link: findpattern create vector x numbers of ones and run findpattern2. e = ones(1,x); fo...

How to find an exact sequence of values?

Try Loren's findpattern2. Here is link: findpattern create vector x numbers of ones and run findpattern2. e = ones(1,x); fo...

presque 5 ans il y a | 0

| A accepté

Réponse apportée

merge parts of arrays of cell array into matrix using loop

Try this: solution = repmat({rand(6,300)},1,6); cC0_ges = reshape(cell2mat(cellfun(@(x) x(1,1:20), solution,'uni',false))...

merge parts of arrays of cell array into matrix using loop

Try this: solution = repmat({rand(6,300)},1,6); cC0_ges = reshape(cell2mat(cellfun(@(x) x(1,1:20), solution,'uni',false))...

presque 5 ans il y a | 0

| A accepté

Réponse apportée

Trouble reading data from .mat file

Hi, Try this: fid = fopen('1.mat'); values = fread(fid); fclose(fid); It seems only file created 'MATLAB 5.0 MAT-file,...

Trouble reading data from .mat file

Hi, Try this: fid = fopen('1.mat'); values = fread(fid); fclose(fid); It seems only file created 'MATLAB 5.0 MAT-file,...

presque 5 ans il y a | 0

Réponse apportée

plotting 2 different sized data into histogram

Try this for your both histograms. Do not use nbins. widthvalue = 0.1; histogram(X,'BinWidth',widthvalue)

plotting 2 different sized data into histogram

Try this for your both histograms. Do not use nbins. widthvalue = 0.1; histogram(X,'BinWidth',widthvalue)

presque 5 ans il y a | 1

| A accepté

Réponse apportée

Convert color map and a corresponding color scale to a matrix of numerical values.

What do you mean by opposite of inbuilt function colorbar? colorbar is a function to create any colorbar near your axis. The ...

Convert color map and a corresponding color scale to a matrix of numerical values.

What do you mean by opposite of inbuilt function colorbar? colorbar is a function to create any colorbar near your axis. The ...

presque 5 ans il y a | 0

Réponse apportée

How do I extract data from a specific subplot in a MATLAB figure?

Hi, If you don't have the handles of the plot in the figure here is a demonstration for you. Please read the comments careful...

How do I extract data from a specific subplot in a MATLAB figure?

Hi, If you don't have the handles of the plot in the figure here is a demonstration for you. Please read the comments careful...

presque 5 ans il y a | 0

| A accepté

Réponse apportée

Property of gscatter information needed

Have you read that? gscatter you don't have to mention a 'Name','Value' pair argument inputs for gscatter. It works like th...

Property of gscatter information needed

Have you read that? gscatter you don't have to mention a 'Name','Value' pair argument inputs for gscatter. It works like th...

presque 5 ans il y a | 0

Réponse apportée

Delete end points from columns in a structure array

I did something like this: newS2 = arrayfun(@(y) structfun(@(x) x(3:end-2),y,'uni',false),S) Or: for i = 1:numel(S) n...

Delete end points from columns in a structure array

I did something like this: newS2 = arrayfun(@(y) structfun(@(x) x(3:end-2),y,'uni',false),S) Or: for i = 1:numel(S) n...

presque 5 ans il y a | 1

Réponse apportée

how to write Conditional for loop in matlab without giving range? and it should run till condition satisfied

You should use while loop instead. Here is the link: while Here is a sample code for your case: K=0; Flag = 1; while Flag ...

how to write Conditional for loop in matlab without giving range? and it should run till condition satisfied

You should use while loop instead. Here is the link: while Here is a sample code for your case: K=0; Flag = 1; while Flag ...

presque 5 ans il y a | 0

| A accepté

Réponse apportée

How to show bin counts' percentage values in Histogram2 tile plot?

I have solved it writing a function manually add text to each rectangle. Here is the function: function hHist = normalized_h...

How to show bin counts' percentage values in Histogram2 tile plot?

I have solved it writing a function manually add text to each rectangle. Here is the function: function hHist = normalized_h...

presque 5 ans il y a | 0

| A accepté

Réponse apportée

Mean of a Matrix

your for loop is length(rand_image_stim). So your mean value calculated 10000 times. You should store it and later get the mean ...

Mean of a Matrix

your for loop is length(rand_image_stim). So your mean value calculated 10000 times. You should store it and later get the mean ...

presque 5 ans il y a | 0

Question

How to show bin counts' percentage values in Histogram2 tile plot?

Hi Dear Community I have x and y values*, I want to plot it like a 3D Histogram but on the top view. (It should look like a he...

presque 5 ans il y a | 2 réponses | 0

Réponse apportée

matlab.graphics.illustration.Legend/set

Hello, Try this, legend_h = legend('TOFA (5uM)... ...'); set(legend_h,'Color','none','...','...'); It seems you have forgot...

matlab.graphics.illustration.Legend/set

Hello, Try this, legend_h = legend('TOFA (5uM)... ...'); set(legend_h,'Color','none','...','...'); It seems you have forgot...

environ 5 ans il y a | 0

Question

How to change tooltip position in AppDesigner?

Hello dear community, I have created a GUI in appdesigner. I created a checkbox with a label text and a button right side of t...

environ 5 ans il y a | 1 réponse | 2

Réponse apportée

How to call xlim and ylim after the most recent zoom?

Hello, Try this: hFig = figure; hAxis = axes(hFig); hPlt = plot(hAxis,rand(100,1)); zoomObj = zoom(hFig); set(zoomO...

How to call xlim and ylim after the most recent zoom?

Hello, Try this: hFig = figure; hAxis = axes(hFig); hPlt = plot(hAxis,rand(100,1)); zoomObj = zoom(hFig); set(zoomO...

environ 5 ans il y a | 0

| A accepté

Question

How to change inputdlg's editbox into a popup menu?

Hellooo dear community! I want to create a small dialog box which contains 2 different popup-menu. Do we have any built-in fun...

environ 5 ans il y a | 1 réponse | 0

Réponse apportée

uitable updates behave strangely

I had that problem before, I simply solved it by changing the focus of the tabs while creating the uitables. Please try followin...

uitable updates behave strangely

I had that problem before, I simply solved it by changing the focus of the tabs while creating the uitables. Please try followin...

environ 5 ans il y a | 0

Réponse apportée

Create a column vector from 15 to -25 with a step size of 5

Hi David, Try this: prob04 = sort(-25:5:15,'descend')

Create a column vector from 15 to -25 with a step size of 5

Hi David, Try this: prob04 = sort(-25:5:15,'descend')

environ 5 ans il y a | 1

Réponse apportée

Preallocating of Structure without overwriting

I can recommend you to use datastore to process multiple files at once. This will be the faster than using xlsread. Actually it ...

Preallocating of Structure without overwriting

I can recommend you to use datastore to process multiple files at once. This will be the faster than using xlsread. Actually it ...

environ 5 ans il y a | 0

| A accepté

Réponse apportée

find all elements (cells) of a single element (cell) in cell array

Maybe you can try this piece of code: cellSizes = cellfun('prodofsize',c); elementIndices = []; elementValues = []; for i...

find all elements (cells) of a single element (cell) in cell array

Maybe you can try this piece of code: cellSizes = cellfun('prodofsize',c); elementIndices = []; elementValues = []; for i...

environ 5 ans il y a | 0

Réponse apportée

What is the best way to save to .csv without losing precision and with column headers?

Hi, Have you tried the functions writematrix or csvwrite ? csvwrite is not recommended right now but you can try it.

What is the best way to save to .csv without losing precision and with column headers?

Hi, Have you tried the functions writematrix or csvwrite ? csvwrite is not recommended right now but you can try it.

environ 5 ans il y a | 0

Question

How to enable datacursormode and zoom for only one axes in a figure?

Hello dear community, I have question about the GUI I made programatically with OOP. I am not using GUIDE or AppDesigner. I ...

environ 5 ans il y a | 1 réponse | 1

Réponse apportée

How can I include a time delay in Simulink of the below equation?

I think you should calculate the z-transform of the e^(-44s) part. It will become a discrete transport delay in simulink. That ...

How can I include a time delay in Simulink of the below equation?

I think you should calculate the z-transform of the e^(-44s) part. It will become a discrete transport delay in simulink. That ...

environ 5 ans il y a | 1

| A accepté

Réponse apportée

how can call a function

You should define the variables you are going to use as inputs of function. The inputs are written in the paranthesis. All outp...

how can call a function

You should define the variables you are going to use as inputs of function. The inputs are written in the paranthesis. All outp...

environ 5 ans il y a | 0

Réponse apportée

Calculate percentage difference between two variables

You should resample one array's elements according to other array's time. Check the below function for this: resample After...

Calculate percentage difference between two variables

You should resample one array's elements according to other array's time. Check the below function for this: resample After...

environ 5 ans il y a | 0

| A accepté

Question

How to create an animated plot of a temperature data with holding on each year?

Hi dear community, I want to create an animated plot of a temperature data. I have 122 files of measured temperatures and I wa...

plus de 5 ans il y a | 1 réponse | 0

Réponse apportée

how can I print some numbers in ascending order?

Hi, Please check out below bubble sort algorithm: https://www.mathworks.com/matlabcentral/answers/364213-matlab-descending-o...

how can I print some numbers in ascending order?

Hi, Please check out below bubble sort algorithm: https://www.mathworks.com/matlabcentral/answers/364213-matlab-descending-o...

plus de 5 ans il y a | 0

Réponse apportée

Dividing a Number with a Vector Results in a new Vector with wrong mean

Because they are not equal mathematically. Suppose that: VectorInit = [a,b,c] meanVectorInit = (a+b+c)/3 VectorTarget = [60...

Dividing a Number with a Vector Results in a new Vector with wrong mean

Because they are not equal mathematically. Suppose that: VectorInit = [a,b,c] meanVectorInit = (a+b+c)/3 VectorTarget = [60...

plus de 5 ans il y a | 2

| A accepté

Réponse apportée

How to save GUI plots

Before you plot, you should save your figure handle into a variable so that you can put it as an input of saveas function. Ins...

How to save GUI plots

Before you plot, you should save your figure handle into a variable so that you can put it as an input of saveas function. Ins...

plus de 5 ans il y a | 0