Answered
Random number of points moving with given velocity
You need a comma after 'Position' : set(MOVINGPOINT,'Position', [trajectory(1,frameNo)-0.25,trajectory(2,frameNo)-0.25,0.5,0.5]...

3 years ago | 0

Answered
how to index the stating position of something?
If you have the Image Processing Toolbox, why not use the power of the bwareafilt function to immediately extract the longest ru...

3 years ago | 0

Answered
how to close error dialog
Fix the code or data so that the errors never occur. Or else just call "return" instead of uiwait(errordlg("You made a mistak...

3 years ago | 0

Answered
How can I add the correct coefficients from exponential curve fitting to the code
I don't get anything like either of your two sets of coefficients. This is what I get: % Uses fitnlm() to fit a non-linear mod...

3 years ago | 1

Answered
New line after fprintf in a for/ while loop
Let's say you loop over val1 to val2, and you want to only enter the loop if val1 is more than 5 and val2 is less than 80. One ...

3 years ago | 0

Answered
Finding the first 1 in a binary set using optimization
Why not simply do V=[zeros(1,10^4) 1 zeros(1,100) 1 1 zeros(1,10^3)]; index = find(V == 1, 1, 'first') ???

3 years ago | 0

Answered
MATLAB standalone App not working when installed on another system
See the FAQ for a list of common reasons your compiled app won't run on a target system: https://matlab.fandom.com/wiki/FAQ#My_...

3 years ago | 1

| accepted

Answered
Compare each spectrum to a reference spectrum.
Try something like this (untested) to compare spectro files to a ref spectro file using RMS. Adapt as needed. % Specify the fo...

3 years ago | 1

| accepted

Answered
The given below i put 100%efforts but do not solve.so please help me. I prepocessed the three signals and added the nm2cm but do not pass the test cases.
MATLAB is case sensitive. You created harp_Cm while it wanted harp_cm with a lower case c. harp_cm = harp; % Duplicate harp an...

3 years ago | 2

| accepted

Answered
Image acquisition in parallel via FireWire
Post a screenshot of what you see when you run imageAcquisitionExplorer or imaqtool If there are two cameras you should see two...

3 years ago | 1

Answered
how to assign a numerical value to an image based on the gray scale present in the image
Hint: function [meanGL, returnValue] = MyHomework(inputImage) meanGL = mean2(inputImage); percentage = %code if percentage >...

3 years ago | 0

Answered
Why does Matlab 2023a crash when running my code?
See support article: https://www.mathworks.com/matlabcentral/answers/157894-resolving-low-level-graphics-issues-in-matlab?s_tid...

3 years ago | 0

Answered
how to extract elements that are not succesive
Here's help: Invest 2 hours of your time here: MATLAB Academy - Free 2 hour training You will learn things like that plus mo...

3 years ago | 0

Answered
how to draw a tangent line between two point (highest points) and draw a perpendicular drop line from mid of the tangent line?
Here's a start. See if you can finish it: x1 = 50; x2 = 62; y1 = 60; y2 = 64; plot([x1, x2], [y1, y2], 'k.-', 'MarkerSize'...

3 years ago | 0

Answered
unable to run the label overlay of original and labeled image for data training on matlab
I'm not sure what your x is, but something like this works fine: x = imread('moon.tif'); % x is a gray scale image. rgbImage =...

3 years ago | 0

Answered
Can a stand alone version be used by anyone?
If you have the Compiler Toolbox in your license, then yes you can distribute the standalone executable to anyone and they can r...

3 years ago | 0

Answered
Complete unexpected GUI-elements behavior
Maybe try to build it from scratch using App Designer instead of GUIDE.

3 years ago | 0

Answered
Count and measure objects in a photo
See my Image Segmentation Tutorial in my File Exchange: Image Analyst's File Exchange It's a generic, general purpose demo of ...

3 years ago | 0

| accepted

Answered
Using methods across multiple class objects of the same class?
If the results are strings, try {MyOperatingPoint.Run.fooProp1} or vertcat(MyOperatingPoint.Run.fooProp1)

3 years ago | 0

| accepted

Answered
how to process multiple video files from a folder
This is one of the most common FAQ questions, so see the FAQ: https://matlab.fandom.com/wiki/FAQ#How_can_I_process_a_sequence_o...

3 years ago | 1

Answered
Undefined function 'imsegkmeans' for input arguments of type 'uint8'.
I don't like that function anyway. K-means is not what you want to do unless you have a good supply of each class in each image...

3 years ago | 0

Answered
segmentation using k-means clustering
Sorry I didn't see this when it was posted 3 years ago. As you can see the whole approach is wrong. K-means is not what you wa...

3 years ago | 0

Answered
Magnifying a Segment of Plot in MATLAB Figure
I'm attaching some of my demos where I insert axes into axes as small insets. Adapt the "inset_plot_within_another_plot.m" fi...

3 years ago | 0

Answered
How to determine resolution of an image in micron/pixel
I believe you can tell your microscope to stamp a "micron bar" into your image. Do that, then calibrate to it. See the attache...

3 years ago | 0

| accepted

Answered
How to make contour smooth
Looks like you used contourf on some gray scale image. You can get smoother contours by blurring your image before calling cont...

3 years ago | 0

Answered
comparing two matrices of different dimensions
Here is an alternate way using pdist2 in the Statistics and Machine Learning Toolbox. % Create simple, sample integer data. A ...

3 years ago | 0

Answered
I have 2D images of black balls and white inter-balls spaces. I want a CNN to recognise the white area. I think it's a grayscale binary image segmentation task
Training with synthetic images and then running on real world images will likely produce inaccurate segmentations and porosity e...

3 years ago | 2

| accepted

Answered
Turning all elements of a column array into the same factor of 10
Try round X = [19.9, 20, 20, 20.1, 20.12, 19.81, 20, 32, 46]; rounded = round(X, -1)

3 years ago | 1

| accepted

Poll


My preferred vacation is to visit

3 years ago | 13709 votes | 15 comments

Answered
Saving and reloading a table
That should work. You'll need to show us how you actually saved it with the save function. What I'd do is %------------------...

3 years ago | 0

Load more