Multiple functions in stats toolbox not working, despite active license?

Hi,
I am running matlab R2018b on my Mac OS with Stats toolbox installed. It was working great for a while but recently it has been giving me errors when I am trying to check assumptions of ANOVA, both for vartestn() and stats.resid.
Here is the code:
[p stat] = vartestn(percent_abs(1,1:63)', 'TestType', 'LeveneAbsolute')
%show equality of variance necessary for ANOVA
res = stats.resid(percent_abs(1,1:63));
%Find residuals of data.
figure(6)
normplot(res)
title('Normal Probabilty Plot for Residuals')
%Plot normality of residuals
I can run vartestn without the test type, but I need to be able to run the Levene test. Here is the error it gives me.
Undefined function or variable 'testname'.
Error in vartestn (line 272)
Table{k+4,1} = testname;
Error in (line 85)
[p stat] = vartestn(percent_abs(1,1:63)', 'TestType', 'LeveneAbsolute')
I also get: Undefined variable "stats" or class "stats.resid".
I've made sure that the toolbox was downloaded and activated. I have used this exact code and these functions before and it worked with no issues. I am thinking it is a toolbox problem since the error refers me to the function in the toolbox for the vartest? Any thoughts would be helpful, TIA.

답변 (1개)

Run these commands from you Caommand Window or a script:
restoredefaultpath
rehash toolboxcache
If you are still having problems after that, use the Contact Support link to request Technical Support.

댓글 수: 2

I tried restoring paths and rehash trick. I'll contact support. Thanks.
My pleasure!
Unfortunate that this didn’t work.

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

카테고리

도움말 센터File Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기

제품

릴리스

R2018b

태그

질문:

2020년 12월 5일

댓글:

2020년 12월 5일

Community Treasure Hunt

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

Start Hunting!

Translated by