フィルターのクリア

How do I scale coordinates for different size

6 ビュー (過去 30 日間)
OriAlpha
OriAlpha 2018 年 12 月 20 日
再開済み: madhan ravi 2018 年 12 月 21 日
Hello,
how to scale different size coordinates
for example,
i have 2 points in graph which is 960 and 882 (this is referance point)
my next point will be 920 and 850
now how can i scale to my referance point
i need make this
Untitled.png
  2 件のコメント
jonas
jonas 2018 年 12 月 20 日
Care to elaborate?
OriAlpha
OriAlpha 2018 年 12 月 20 日
編集済み: OriAlpha 2018 年 12 月 20 日
my current value which is 920,850 i have to get new value interms of 960,882
its about adjusting the scale

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

採用された回答

Star Strider
Star Strider 2018 年 12 月 20 日
I am not certain what you want.
Try this:
Scale = [920 1; 850 1] \ [960; 882]
NewValue = [920 1; 850 1] * Scale
producing:
Scale =
1.114285714285713
-65.142857142856428
NewValue =
960
882
This simply does a linear regression (of sorts) between the old value and the new value.
  2 件のコメント
OriAlpha
OriAlpha 2018 年 12 月 20 日
Untitled.png
Star Strider
Star Strider 2018 年 12 月 20 日
You changed the numbers in your Question, so just change the numbers in the ‘Scale’ calculation in my Answer:
Scale = [920 1; 850 1] \ [960; 870]
NewValue = [920 1; 850 1] * Scale
producing:
Scale =
1.28571428571428
-222.857142857142
NewValue =
960
870

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLine Plots についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by