Réponse apportée
gamma function with two parameters
Is this the function you mean to use? <https://www.mathworks.com/help/matlab/ref/gammainc.html>

environ 2 ans il y a | 0

Réponse apportée
How can I keep track of a constantly updating text file's latest string
The following function returns a string containing the last non-empty line of text in the file (or "" if there are none). Call ...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
for loop jump an element of an array
From the documentation for the colon operator: "x = j:i:k creates a regularly-spaced vector x using i as the increment between ...

environ 2 ans il y a | 0

Réponse apportée
How to concatenate multiple Tables by comparing it to the variables associated with individual tables in workspace.
"This Would not work if any of the cases under the IF & elseif aren't satisfied then this table will not be Concatinated. " Tha...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
How to create function with name-value pair arguments?
fcn('name','booey','professional_life','noine','personal_life',2,'tooth_size','XXXL') fcn('name','Fred','home_planet','Mars','t...

environ 2 ans il y a | 1

Réponse apportée
paint the circle in half
pos = [2 120 2 2]; color = [0 0.5 0.5]; r = pos(3)/2; c = pos([1 2])+r; th = linspace(-pi/2,3*pi/2,101); % <- use an odd n...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
How to get a normal box plot graph we get in origin software which consist of box plot with data points scattered and normal distribution curve in MATLAB
Maybe something like this. This fits distributions to the data, but if you have the distributions already you can plot them the ...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
How to resolve reshape error
Pick an N that's a multiple of k, or adjust N to be a multiple of k in the code, or append enough bits onto the end of the bit s...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Speeding up lookup in large tables
Here's one way that could work, if you have enough memory to generate the idx matrix, which is of size [size(A,1) x size(B,1)] ...

environ 2 ans il y a | 2

| A accepté

Réponse apportée
How to remove a specific class in the confusion matrix?
load testCells x = removecats([trueCellR{:}],'n/a'); y = removecats([testCellR{:}],'n/a'); x = reordercats(x,[3 2 1]); ...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
How do I change the colors of Stack Plot bars for different variables
One way is to set the FaceColor directly: % random data: x_values = 1:10; data = rand(10,5); color1 = [0.3, 0.5, 0.7]; %...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Handling data form structures
% Specifying the direction and file type direction = '.'; type = '*.txt'; Data = dir(fullfile(direction,type)); % Getting a...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
How to extract numbers against a certain text name in a text file containing time stamp data
str = fileread('sampletext.txt'); C = regexp(str,'DA2.0:(.*?)\r?\n','tokens'); vals = str2double([C{:}])

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Error message "Invalid use of operator"
Looks like you mean to say: grad_all((ii-1)*2+[1 2],:) = -grad;

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Connect Matlab with chatgpt
May be useful: https://www.mathworks.com/matlabcentral/answers/1894530-connecting-to-chatgpt-using-api

environ 2 ans il y a | 1

Réponse apportée
How to write in Matlab a matrix whose coefficients depend on a real alpha parameter
Here's an example: alpha = 0.4; N = 9; x = linspace(0,1,N); y = linspace(0,1,N); xy = x(:).*y(:).' % column x * row y ...

environ 2 ans il y a | 0

Réponse apportée
How to multiply numbers if they meet a certain condition?
V = [5, 17, -3, 8, 0, -7, 12, 15, 20, -6, 6, 4, -7, 16] idx = V>0 | rem(V,3)==0 Now idx is a logical vector saying whether eac...

environ 2 ans il y a | 1

| A accepté

Réponse apportée
uitabe : Empty Space is not fill with data
The amount of empty space (if any) is determined by the Position and ColumnWidth properties of the uitable. Try changing those ...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
How to read shape file in matlab?
You are attempting to read a file in the current directory: S = shaperead(shapefile.name); That is, you are not taking into ac...

environ 2 ans il y a | 0

Réponse apportée
Using surf function with data from excel table
It would help to have the data, in order to know whether the x and y are gridded or scattered. https://www.mathworks.com/help/m...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Find frequency of words from different books
Maybe this will help: % example data: counts = { ... {'the' 464; 'project' 87; 'of' 253} ... {'the' 300; 'of' 314; '...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
How can I subtract every element in an array (including the first element) from the first element of the same array
v = 3:4:15 % an array v-v(1) % subtracting the first element from each element v(1)-v % subtracting each element from the firs...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Issue with UI Components Not Resizing Correctly on Window Maximize in App Designer
The thing I would do (and what I generally do in any GUI) is to turn AutoResizeChildren 'off' and write my own SizeChangedFcn fo...

environ 2 ans il y a | 0

Réponse apportée
How to get all possible combination With the total number of possible combination for "n" variables that can take different values
a = [1 99]; b = [2 30 700]; c = [4 55 666 8888]; vars = {a,b,c}; n = numel(vars); out = cell(1,n); [out{:}] = ndgrid(var...

environ 2 ans il y a | 0

Réponse apportée
How to write output data in excel csv files?
After the for loops: writematrix(avg_village_ndvi,'c:\data\ndvi_predictors.csv') writematrix(avge_village_ndre1,'c:\data\ndre1...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Control and use greek letter of the contour diagrams
Here's how you can incorporate a Greek letter into the contour labels: x = 10.^(0:6); y = 0:10:200; z = (1+y).*log10(x.')/400...

environ 2 ans il y a | 0

Réponse apportée
Novice question - Push button to display y intercept
The reason the red line disappears when you move a slider is that plot replaces whatever is in the axes with the newly plotted l...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Figure open on every run
You should use ishandle, ishghandle, or isgraphics instead of isvalid. Also, make sure you don't have a clear or clear all stat...

environ 2 ans il y a | 0

| A accepté

Réponse apportée
Changing live uitable row colours depending on value.
Since you are coloring by row, setting the uitable's BackgroundColor may work for you. You can use a matrix of colors. Example:...

environ 2 ans il y a | 0

Réponse apportée
yyaxis causing values on y-axes to become incorrect
The lines corresponding to the right y-axis are all plotted with LineStyle 'none' and no marker, so they don't appear at all. In...

environ 2 ans il y a | 1

| A accepté

Charger plus