interpolate (using interp) with a decimal number

조회 수: 4 (최근 30일)
Giorgis
Giorgis 2017년 5월 2일
댓글: Star Strider 2017년 5월 4일
Hi
I'm trying to interpolate using a non-integer number as required by interp command. Is there another function that would allow interpolation using a decimal number please?
Thanks

채택된 답변

Star Strider
Star Strider 2017년 5월 2일
편집: Star Strider 2017년 5월 2일
I am not certain what you are asking. If you have integers and want to interpolate to the nearest integer, use the 'nearest', 'next', or 'previous' method option in your interp1 call.
You could also use the 'linear' method and the use floor, ceil, fix, or round to produce integer output from interp1.
  댓글 수: 6
Giorgis
Giorgis 2017년 5월 4일
You are quite right. I had to run a few examples and see that the lowpass filter changes the signal insignificantly. Thanks and good day!
Star Strider
Star Strider 2017년 5월 4일
Thank you!
My pleasure!
May the Fourth be with you! (Today is ‘Star Wars Day’!)

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Interpolation에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by