a single programm for both horizontal and vertical

vertical and horizontal allignment

8 件のコメント

Walter Roberson
Walter Roberson 2022 年 8 月 4 日
You should show the outline of the code.
PA
PA 2022 年 8 月 10 日
i need the horizontal elementls like the image 3. i went over my code and found no issue but still the horizontal ones are not allign and they are like the first image
Walter Roberson
Walter Roberson 2022 年 8 月 10 日
theta = atand(delta_X/delta_Y);
That should probably be
theta = atan2d(delta_Y, delta_X);
If you stick with atand() then it should be delta_Y/delta_X -- opposited divided by adjacent.
PA
PA 2022 年 8 月 11 日
Thanks Walter but it didnot work.
Walter Roberson
Walter Roberson 2022 年 8 月 15 日
for i =1: size(patternline, 1)
So i starts at 1
Delta_X = patternline(i-1,2) - patternline(i-1,4);
i started at 1. Delta_X = patternline(1-1,2) - patternline(1-1,4). That is a reference to index (0,2) and index (0, 4). Those indices do not exist
PA
PA 2022 年 8 月 15 日
okay but when i write this for i = 2:size(patternline,1) for loop i also get the same error
Image Analyst
Image Analyst 2022 年 8 月 15 日
Attach importPattern.m
If you have any more questions, then attach your data and code to read it in with the paperclip icon after you read this:

サインインしてコメントする。

回答 (0 件)

カテゴリ

タグ

質問済み:

PA
2022 年 8 月 4 日

コメント済み:

2022 年 9 月 1 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by