Answered
When I am running this code I am getting following errorUnable to perform assignment because the indices on the left side are not compatible with the size of the right side.
It's not really clear what the intent is. If I assume that you want each iteration to produce a 5x1 column vector in the outp...

4 years ago | 0

Answered
Cell concatenation error with cells with values below 1 and above 1
Again, the question is whether you want to treat these as text or as numeric values for subsequent calculations. If you want th...

4 years ago | 0

Answered
What is wrong in my code for converting from rgb to yiq and from yiq to rgb
Old question, I know. It's still getting traffic, so I might as well... The problem with this specific attempt is twofold. On...

5 years ago | 0

Answered
Why am i recieving "Array indices must be positive integers or logical values"?
Observe the values of the indices that are causing the problem. Find why they're being set as they are. V = [0 0 0 0 1 0 0 0 0...

5 years ago | 0

| accepted

Answered
How do I load and plot the .mat file
This is one way: S = load('lab31part1.mat'); t = S.lab3_part1_Time; v = S.lab3_part1_Value; subplot(2,1,1) plot(t(:,1),...

5 years ago | 0

Answered
Draw surface of a football (American)
Two things to notice: note the way your points are spaced unevenly along z compared to the reference image. Also note the restr...

5 years ago | 1

| accepted

Answered
How to plot a circle with polar coordinates in which the colour of the circle changes by data?
Something like this may suffice. It probably needs quite a bit of tweaking (labels, titles, geometry adjustment) still, but it'...

5 years ago | 0

| accepted

Answered
How to find Hue and chroma values of images
If you're working in LAB and you want Hue and Chroma (i.e. the polar representations of the model you're already in) then I don'...

5 years ago | 0

Answered
How can I convert RGB image to NTSC without using 'rgb2ntsc' command?
It can be a lot simpler. rgbpict = imread('peppers.png'); rgbpict = im2double(rgbpict); % pay attn to match class and sc...

5 years ago | 0

Answered
how to convert RGB to YUV ?
Tools like imshow() are not intended to view anything other than simple intensity or RGB data. They assume certain conventions ...

5 years ago | 0

Answered
how to convert RGB to YIQ color space ?
Image Processing Toolbox has rgb2ntsc() and ntsc2rgb() which do YIQ conversion without the need for anything external. https:...

5 years ago | 0

Answered
How can I compare one image to multiple images?
Consider the example: % test images A = imread('cameraman.tif'); I = {A,imnoise(A,'gaussian'),imnoise(A,'gaussian'),imnoise(A...

5 years ago | 0

Answered
Is there a direct function for RGB to YUV color space conversion? please help
Old post, I know... Gotta put a reference answer somewhere. Assuming that OP actually wants what they say they want, then no, ...

5 years ago | 0

Answered
How to visualise the colour with a given set of RGB values?
If you just want a small swatch to see the color: c = [85 250 100]; % color tuple scaled to [0 255] imshow(ones(80).*permute(c...

5 years ago | 0

Answered
volume of solid generated by revolving a curve about y axis or parallel to y axis
Same story, just transpose everything. syms y; % what is the value of requiring the user to manually re-enter data % ever...

5 years ago | 1

| accepted

Answered
Working with color maps
You'll probably have to label things and whatnot. Could be done with tiledlayout() too, but I never use that. [A map] = imread...

5 years ago | 0

Answered
Not sure how to get to the answer
If x = [2 1], then x-1 = [1 0]. 1^n is 1 for any n 0^n is 0 for any positive nonzero n

5 years ago | 0

Answered
not enough input arguments
syms x f = x^2*exp(sin*x)-x/x^3+1; f = x^2*exp(sin(x))-x/x^3+1; % ?

5 years ago | 0

Answered
How can i rearrange expressions?
Consider: syms a b D S L X Y Z e1 = D == -(X*cos(a)+Z*sin(a))*cos(b) - Y*sin(b); e2 = S == (X*cos(a)+Z*sin(a))*sin(b) - Y*cos...

5 years ago | 1

| accepted

Answered
MATLAB command to calculate the value of sin(0.5pi)+27+2i-2
MATLAB doesn't support implicit multiplication, so that's all you need to add sin(0.5*pi)+27+2i-2 It's such a bunch of perfect...

5 years ago | 0

Answered
Comparing arrays and getting the index of extra rows
Consider: % example arrays B = randi(99,5,3) A = [B; randi(99,3,3)]; A = A(randperm(size(A,1)),:) % i'm assuming C is some ...

5 years ago | 0

| accepted

Answered
How to call a variable from output of a loop in another loop?
It doesn't have anything to do with accessibility of the variable. It's a problem with using a logical test on a floating point...

5 years ago | 0

| accepted

Answered
Colorbar of the plot and not the backgorund image
Well, there's a bit of a problem trying to do that. The way you're doing things, you have a bunch of plot objects which are exp...

5 years ago | 1

| accepted

Answered
How to store photos taken in for loop?
You're not saving anything. You're displaying the image and then discarding it. The output of image() is not an image array. ...

5 years ago | 0

| accepted

Answered
For loop not working through matrix
You're overwriting the file every single time you write a line. That's the difference between opening the file with 'w' permiss...

5 years ago | 0

| accepted

Answered
What does this means "Undefined function 'hist3' for input arguments of type 'cell' and Error in 3h_WorkspaceData (line 142) Z1 = hist3([LData_eyewall(:,8) LData_eyewall(:,7)]
It means that you don't have hist3(). That's probably because you don't have the stats toolbox. If you did have hist3() and ...

5 years ago | 0

| accepted

Answered
How to save picture with black backgroud?
Try this: https://www.mathworks.com/matlabcentral/answers/100905-why-does-my-figure-print-with-a-white-background-and-white-axe...

5 years ago | 0

| accepted

Answered
Rescale a grayscale image
Consider the following image. The image content does not span the extent of the allowable range. A = dicomread('CT-MONO2-16-an...

5 years ago | 1

| accepted

Answered
4D figure with a colormap
Well, dicomCollection() won't run in-browser, but see if this is what you're after: dir = fullfile( matlabroot, 'toolbox/images...

5 years ago | 0

| accepted

Answered
Calculate with different sized matrixes
A = randi(9,1,10) % a short vector B = randi(9,1,17) % a long vector % interpolate to shorten the long vector Bs = interp1(1:...

5 years ago | 0

| accepted

Load more