How to plot both horizontal and vertical profile for the same image?
Show older comments
Hi. I'd like to plot a line profile across the beam and plot both horizontal and vertical profile on the same image. I manage to get one. I cannot plot the vertical profile and make it on the image together. Please give me any suggestion and help.Thank you.
% code
clc;close all;clear all;
img=imread('e_foil_spot.png');
img2=imcrop(img);
figure(1), imshow(img2);
c= improfile; hold on;d=improfile; % get the lime profile across
b=c';
% Plot the line profile on the same image
figure(1); imshow(img2); colormap('jet');
hold on; plot(b/(0.03*max(b)),'color', 'g','LineWidth', '10');
hold on; plot(d/(0.03*max(d)),'color', 'y','LineWidth', '10');
hold off

Accepted Answer
More Answers (0)
Categories
Find more on Display and Exploration in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
