You can consider converting your angles from radians to degrees if needed, and ensure you are using the correct plotting function for your data. The 'polar' function is typically used for polar plots which might not directly give you a sky plot. Instead, you can use the 'polarplot' function for better control or convert to Cartesian coordinates for a more customized plot.
Here's how you can do it:
azimuth_deg = rad2deg(azimuth);
elevation_deg = rad2deg(elevation);
% Convert elevation to a form suitable for plotting
r = 90 - elevation_deg; % assuming elevation is from 0 (horizon) to 90 (zenith)
% Create the polar plot
polarplot(deg2rad(azimuth_deg), r, 'o');
% Adjust the plot
ax = gca;
ax.ThetaZeroLocation = 'top'; % Set 0 degrees at the top
ax.ThetaDir = 'clockwise'; % Azimuth increases clockwise
ax.RDir = 'reverse'; % Reverse the radial direction
ax.RLim = [0 90]; % Limit the radial axis from 0 to 90 degrees
% Labels
title('Sky Plot');
You can adjust the code as needed based on your specific data and desired visualization.