Computer crashes/restarts when running stepwiseglm
Show older comments
Hello,
I'm running a simple script that runs a GLM using stepwiseglm. I've tried to run the code 6 times now and each time my computer unexpectedly crashed/restarted on its own. Sometimes it crashes soon after I run the script (minutes), sometimes it runs for hours and stepwiseglm produces output (list of components that it included in the model), but it never seems to finish.
Has anyone run into something like this?
My system:
MATLAB 2018b
Win 10 pro
10.0.17134 build 17134
Thanks for any insights!
Script code:
------------------------------------------
%load data
load('B01_POS_NEG.mat')
ResponseVar = B01_POS_NEG{:,10};
PredictorsVar = B01_POS_NEG{:,11:138};
%compute Generalized Linear Model
size = length(PredictorsVar);
%1. stepwise
IncludeP = 0.01; %maximum p-value allowed for included components
ExcludeP = 0.05; %minimum p-value to exclude component
mdl = stepwiseglm(PredictorsVar,ResponseVar,'linear','Distribution','binomial','Link','logit','PEnter',IncludeP,'PEnter',ExcludeP);
%Select linear predictors
scores = mdl.Fitted.LinearPredictor;
------------------------------------------
The B01_POS_NEG variable has 14815 rows and 138 columns, about 15Mb.
3 Comments
Walter Roberson
on 23 Jul 2019
I recommend that you check for a hardware memory problem.
Walter Roberson
on 23 Jul 2019
https://www.techrepublic.com/article/how-to-detect-bad-ram-with-the-windows-memory-diagnostic-tool/
Luka Zevnik
on 23 Jul 2019
Answers (1)
Luka Zevnik
on 23 Jul 2019
0 votes
Categories
Find more on Noncentral t Distribution in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!