A résolu


Combine the first and last names
MATLAB R2016 provides a rich set of functions to work with string arrays. In this problem, you will be given two string arrays o...

presque 8 ans il y a

A résolu


Words Count: A String Array Approach
Given an input character vector consisting of words, punctuation marks, white spaces, and possibly newline characters (\n), arra...

presque 8 ans il y a

A résolu


How Many Months Until It's Today Again?
Given a particular date, calculate how many months must pass before that same day of the month occurs on the same day of the wee...

presque 8 ans il y a

Réponse apportée
how to concatenate mat files of different row sizes but same column size vertically?
In this line of code: Fv_ROI_concatenated = [a.TwoD_fv_roi_rangefilt_bdip,b.TwoD_fv_roi_rangefilt_bilateral,c.TwoD_fv_roi_r...

presque 8 ans il y a | 0

Réponse apportée
Better skeletonization of an image to found branchpoints
Dilate your image before skeletonize it. Try this: %read image G = imread('grid.jpg'); G = im2bw(rgb2gray(G)); %di...

presque 8 ans il y a | 0

Réponse apportée
Is there an clustering algorithm with which I can declare expected centroid in advance?
The <https://it.mathworks.com/help/stats/kmeans.html k-means clustering> is what you need. You can start the algorithm by select...

presque 8 ans il y a | 0

Réponse apportée
Creatig a matrix from variables in workspace
How did you get these variables? It is not good practice to handle workspace variables after their definition. Better saving...

presque 8 ans il y a | 1

Réponse apportée
how to save values in variable from loop
Save vector |a| before printing: a = 1:10; for k=a fprintf('%d\n',k); end a Outputs: 1 2 .... ...

presque 8 ans il y a | 0

Réponse apportée
how can i solve this equation on matlab?
<https://it.mathworks.com/help/matlab/ref/ode45.html>

presque 8 ans il y a | 0

Réponse apportée
Legend horizontal orientation doesn't work when extracting icon handles
As far as I know the syntax |[lgd,icons,plots,txt] = legend(..)| is not reccomended. Notice in fact that by simply calling |icon...

presque 8 ans il y a | 2

| A accepté

Réponse apportée
How to make a road lane for a synthetic image in gray scale?
Here it is: %create one element Z = zeros(100,101); %lateral lanes Z(:,[11:15,87:91]) = 1; %mid lane (dashed) ...

presque 8 ans il y a | 1

| A accepté

Réponse apportée
Finding real roots of a cubic equation
To force the |vpasolve| finding only real solutions you cannot use |assume|. If you know the real solution is only one a workaro...

presque 8 ans il y a | 0

Réponse apportée
How do I remove/replace border pixels from my image?
You basically don't need your |interior_blackPixels|. Indeed, your expected image is obtained by simply setting |outer_blackPixe...

presque 8 ans il y a | 0

| A accepté

Réponse apportée
Custom Dendrogram Ordering Implementation
Apparently, none of the available functionalities of |optimalleaforder| does the work. So here it is a function that runs throug...

presque 8 ans il y a | 0

| A accepté

Réponse apportée
Find the x value from a specific iteration of fmincon
From the help page about Output Functions <https://it.mathworks.com/help/matlab/math/output-functions.html Output Functions> you...

presque 8 ans il y a | 0

| A accepté

Réponse apportée
Setting Viewpoint with Azimuth, Elevation, and distance
Hi Viet, in order to control visualization in the current axes, consider these parameters also: CameraPosition CameraPos...

presque 8 ans il y a | 1

| A accepté

Réponse apportée
How to plot a function file
Given a vector |y| of dice outcomes, plot the stairwise graph like this: y = [0,3,5,9,2]; X = [0,repelem(1:length(y)-1,2...

presque 8 ans il y a | 0

Réponse apportée
Boundary function fails, R2016b
Hi Jukka, if you look at the plot of the boundary without superimposing it to the circles you can see (see first image below) th...

presque 8 ans il y a | 1

| A accepté

Réponse apportée
FFT Convolution on Wav File
Is your audio file |x| (loaded with |[x Fs]=audioread('drums.wav');| ) stereo? Because in this case the line X = fft( [x ; ...

presque 8 ans il y a | 0

Réponse apportée
obtain cluster label on data
If you applied |kmeans| function like this: idx = kmeans(X,k) then |idx| is the vector containing the labels.

presque 8 ans il y a | 0

| A accepté

Réponse apportée
K-means: see the initial centroids
Yes it is possible. |kmeans| allows you to set option parameters via the |statset| function. In the help page <https://it.m...

presque 8 ans il y a | 1

| A accepté

Réponse apportée
Problem Fitting data to 3 Gaussians
More efficient using built-in code to fit Guassian distributions. Try look at this function which allows you to choose the numbe...

environ 8 ans il y a | 0

Réponse apportée
How do I put minor ticklabel on and ticklabel off ?
One solution can be to set y-limits to larger values, and then force the labels to be the original ones. This way, the labels wi...

environ 8 ans il y a | 0

Réponse apportée
How to map the values from 0-320 to 0-29
Just multiply your values by 29/320; k = 29/320; %generate some random numbers between 0 and 320 x = 320*rand(5); ...

environ 8 ans il y a | 0

A résolu


Stuff the Board
You have a stack of tiles to put onto an array-like playing board. Each tile has a number (always an integer), and the board var...

environ 8 ans il y a

Réponse apportée
Normal Distribution Probability Finder
pp = makedist('Normal','mu',0,'sigma',1); yourP = 1-cdf(pp,-2.125)

environ 8 ans il y a | 4

| A accepté

A résolu


Generalised Hamming Number
Inspired by Project Euler n°204 and Problem 1308 by James A generalised Hamming number of type n, has no prime factor larger ...

environ 8 ans il y a

A résolu


Return a list sorted by number of occurrences
Given a vector x, return a vector y of the unique values in x sorted by the number of occurrences in x. Ties are resolved by a ...

environ 8 ans il y a

A résolu


Quote Doubler
Given a string s1, find all occurrences of the single quote character and replace them with two occurrences of the single quote ...

environ 8 ans il y a

A résolu


Replace NaNs with the number that appears to its left in the row.
Replace NaNs with the number that appears to its left in the row. If there are more than one consecutive NaNs, they should all ...

environ 8 ans il y a

Charger plus