Respondida
Write a program to display your name , ID and average of your ID digits. using matlab
Well, if I'm going to give away clues in comments, I might as well at least give this: If you use a char vector for your ID var...

más de 5 años hace | 0

Respondida
How to add common legend at the end (Bottom Side) of the whole image
Adam's answer is the elegant solution, but if you're using something older than R2020b, or if you're not using tiledlayout, you ...

más de 5 años hace | 1

Respondida
The Average of the Matrix G with the dimension (M,n) that I'm repeating 3 times in a loop so I'll have 3 matrices of G (M,n) and I want to take the Average of these 3 matrices so I can get only one matrix of G(M,n) represent the Average of them)
Something like this M=5; n=3; freq = 28e9; lambda = physconst('LightSpeed')/freq; d_BS=lambda/2; %Inter-antenna separation ...

más de 5 años hace | 0

| aceptada

Respondida
How to Create function for developing n*n matrix?
There's already a built in demo for this. Type help spiral or open it n = 5; A = spiral(n) s = sum(1:2:n^2)

más de 5 años hace | 1

| aceptada

Respondida
Need to speed up the generation of random numbers.
At least in my tests, this is somewhat faster: n = 10; A = randi(5,n,n,n); % generate test array rv = rand(sum(A(:)),1); % ...

más de 5 años hace | 0

Respondida
how to generate below sawtooth pulse
The super-explicit way: x = [0 1 1 2 3 3 4 5 5 6 7 7]; y = [0 1 0 0 1 0 0 1 0 0 1 0]; plot(x,y) You could build those sequ...

más de 5 años hace | 0

Respondida
Error with Imresize as a result of one image file not being in binary
You're using imresize with a completely invalid syntax. Neither of these is an indexed color image or colormap in the sense tha...

más de 5 años hace | 0

Respondida
Imfuse two images together from different sizes
If the images are different sizes, you need to at least know where to put one image with relation to the other -- i.e. an offset...

más de 5 años hace | 0

Respondida
How to plot stairstep between two line?
I've never had to do this before, but this is what I came up with. % just some similarly-shaped curves x = linspace(0.1,1,10...

más de 5 años hace | 0

| aceptada

Respondida
Index in position 1 is invalid. Array indices must be positive integers or logical values.
You are using sortrows as both a variable name and as a function. Rename the variable so that it doesn't overload the function ...

más de 5 años hace | 0

| aceptada

Respondida
How do I declare a for loop with a given number of elements?
consider using linspace() for j = linspace(0,0.03,100) % do things end

más de 5 años hace | 0

Respondida
Error in multiplying corresponding matrix elements
ctrl-f A1_m Look closely and you will see that these are not the same variable names Al_m= [Al_i1 Al_i2 Al_i3]; % ... Alka= ...

más de 5 años hace | 1

| aceptada

Respondida
How to count the number of pixels inside a region
In addition to the ways Image Analyst suggested, I suppose there's another possibility if you're using circle roi objects. A ...

más de 5 años hace | 0

Respondida
Calculating area between individual points that create a curve
There are probably a bunch of ways to do this. Considering that the endpoint trajectories are not aligned to the reference grid...

más de 5 años hace | 0

| aceptada

Respondida
How to use "imhistmatch" for 3D images?
imhistmatch() operates on pages of a 3D array independently. For two images with the same number of pages, each page is matched...

más de 5 años hace | 0

Respondida
imhistmatch() output is zero matrix
I know this is old, but I'm bored and don't mind talking to ghosts. Most image processing tools expect image data to be scale...

más de 5 años hace | 0

Respondida
Unable to perform assignment because the left and right sides have a different number of elements.
The result of the vpasolve() call is a vector of multiple solutions (3). The result of operations on h with scalars is still a ...

más de 5 años hace | 0

Respondida
Checking whether string exist in a cell and read its ID
Something like this may work LUT = {'banana',12; 'orange',23; 'apple',35; 'peach',74; 'pear',51...

más de 5 años hace | 2

Respondida
What does this code give o/p as?
If you're asking what the output is (maybe you're away from a computer with Matlab at the moment) keyg=zeros(8,8); key=[0 0 1 ...

más de 5 años hace | 0

| aceptada

Respondida
How can I insert numbers 1-100 into the first column of a cell array?
Someone can surely improve on this, but this is one way C = cell(10,4) % i'm just going to use a smaller example array C(:,1) ...

más de 5 años hace | 0

Respondida
how do you revese the direction of an axis on a sub plot
Set the properties after the call to imagesc(), otherwise they get reset A = imread('cameraman.tif'); subplot(1,2,1) images...

más de 5 años hace | 0

Respondida
Why isn't this file loading method working?
myfilename is a string containing the filename load(myfilename) passes the string "theta_stuff_acoustics.mat" to load() (and ...

más de 5 años hace | 0

Respondida
How to show multiple images in the same figure and ensure that each image pixel is shown as a screen pixel?
The 'InitialMagnification' parameter doesn't really work in any way that seems to be helpful for controlled resolution output. ...

más de 5 años hace | 0

Respondida
Someone help me do this question
Consider two different approaches n = 15; % how many points to plot r = 2; th = linspace(pi,2*pi,n); x = r*cos(th); y = r...

más de 5 años hace | 0

Respondida
Help me with Graph plot
https://www.mathworks.com/help/matlab/ref/plot.html This is some of the most rudimentary stuff with the most abundant supply of...

más de 5 años hace | 0

Respondida
HSV HSB HSL color space
They're not color spaces themselves. They are just mappings of the RGB colorspace. They are not identical. In HSV, [1 0 0] a...

más de 5 años hace | 1

Respondida
how can i covert rgb image to HSI and separate the intensity component alone
If you just want the intensity (as in HSI) of an image: ipict = mean(rgbpict,3); If instead you want value (as in HSV) vpict ...

más de 5 años hace | 0

Respondida
How to remove outlier of time series signal data by using cubic spline interpolation?
If you want to use normal tools, x=[180 142 213 78 90 192 40 38 105 162 270 262 211 170 72 28 40 55 90 201] L = numel(x); ...

más de 5 años hace | 0

| aceptada

Respondida
Extract elements of each cell to form a matrix and store it. Can anyone give me suggestions?
This is what I did: % build test array a = [1 2 3 4].'; b = [2 3 4 5].'; c = [5 4 4 5].'; d = [7 3 4 5].'; e = [1 3 4 5].'...

más de 5 años hace | 1

| aceptada

Respondida
Can anybody help me with the two questions below in the image? Thanks in advance
Consider this partial solution for part 2 using some simplifications based on the binning and a basic lookup table. This could ...

más de 5 años hace | 0

Cargar más