ttest2 negative value

조회 수: 11 (최근 30일)
Anass John
Anass John 2019년 1월 14일
댓글: Star Strider 2019년 1월 14일
Hi all,
having two vectors x and y, I would like to test which one has the smallest mean with ttest2. I saw in an paper describing rapidly the ttest2 function that it could return either 1 (if mean(x) > meay(y)) or 0 (if mean(x)==mean(y)) or -1 (if mean(x)<mean(y)). However, in the official documentation, there is no negative which can be returned .
Are the information I got false ? How can obtained the described return results ? (1 or 0 or -1).
Many thanks

채택된 답변

Star Strider
Star Strider 2019년 1월 14일
It would help to know what MATLAB version (release) you are using. I am not aware that option ever existed.
If you want to specifically test that the first mean is different from, greater than, or less than the second mean, use the 'Tail' (link) name-value pair argument.
  댓글 수: 2
Anass John
Anass John 2019년 1월 14일
Thanks for your repsonse. I'm using the R2018b version. I think as you said, maybe this option doesn't exist anymore. Thank you for the confirmation
Star Strider
Star Strider 2019년 1월 14일
My pleasure.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

태그

제품


릴리스

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by