MATLAB: How to view the format of a sample data in matlab e.g. “load readmissiontimes” (survival analysis) survival analysis Load the sample data. load readmissiontimes I want to have a look at the readmissionstimes data. Best Answer The variables in that .mat file are:Age 100x1 800 double Censored 100x1 800 double ReadmissionTime 100x1 800 double Sex 100x1 800 double Smoker 100x1 800 double Weight 100x1 800 doubleSo you have data for 100 subjects.The dependent variable is ReadmissionTimehist(ReadmissionTime)gives you a histogram of that data. Related SolutionsMATLAB: Least square fit (regression analysis) The y vector must be columnr = inv(A1'*A1)*(A1'*y(:)); MATLAB: How to calculate AIC in glmfit It is recommended to use fitglm instead of the older glmfit. Depending on the release of MATLAB (> R2012a) you can use either of the two:http://www.mathworks.com/help/stats/fitglm.htmlhttp://www.mathworks.com/help/stats/generalizedlinearmodel.fit.htmlYou can access AIC, BIC etc as follows:load hospitalmodelspec = 'Smoker ~ Age*Weight*Sex - Age:Weight:Sex';mdl = fitglm(hospital,modelspec,'Distribution','binomial')mdl.ModelCriterionans = AIC: 137.141380948166 AICc: 138.358772252513 BIC: 155.377572250082 CAIC: 162.377572250082 Related QuestionCalculating constant hazards in exponential survival distributionsPDF data analysis and comparison
Best Answer