Merge 2D plot with polar plot
古いコメントを表示
Hello, I would like to merge two different plots in a single one like a 2D plot with a polar plot like it is shown in the image below. I would apreciate the help.

Thank you for your help.
2 件のコメント
Mathieu NOE
2024 年 1 月 15 日
hello
it is certainly doable , so what's your issue ?
do you have some data ? code ?
Jorge Luis
2024 年 1 月 16 日
採用された回答
その他の回答 (1 件)
Jorge Luis
2024 年 1 月 16 日
0 投票
2 件のコメント
Jaime Abad Arredondo
2024 年 1 月 16 日
Then it is just a matter of using a hold command to have the two plots together. Importing the data, going from polar to cartesian coordinates and plotting everything together you should get the desired plot...
data_cart=readmatrix('plot1.txt');
data_pol=readmatrix('plot2.txt');
plot(data_cart(:,1),data_cart(:,2),'b')
hold all
plot(data_pol(:,2).*cosd(data_pol(:,1)),data_pol(:,2).*sind(data_pol(:,1)),'r')
Jorge Luis
2024 年 1 月 16 日
カテゴリ
ヘルプ センター および File Exchange で Polar Plots についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

