# Questions tagged [diagnostic]

Diagnostic measures (such as residuals or some summary statistics calculated from residuals) are used to evaluate some aspect of quality of model fit to data.

372 questions
Filter by
Sorted by
Tagged with
9 views

### DHARMa plots diagnostic

I have performed a linear regression analysis using R and generated some diagnostic plots by using package DHARMa (in R). However, I am having trouble interpreting these plots and would appreciate any ...
17 views

### Checking assumptions of ANCOVA

I'm trying to run one-way ANCOVA on my data set in R. My dependent variable is continuous, my independent variable is categorical with 4 levels, and my covariates are categorical: One with 2 levels, ... 9 views

### How to analysis the potential correlation for two different variables at multi-time-point?

We plan to conduct a study about a heart congenital disease. All of the patients have received the same surgical procedure. Everyone was received the ultrasound detection at 3 days preoperative, 7 ...
21 views

### Diagnostic Test needed for ARMAX Model Specification

I'm trying to fit an ARMAX model using forecast::Arima() which is using MLE (https://otexts.com/fpp3/arima-estimation.html). Thus, there is no need for normality test as required by OLS estimator. I ...
16 views

### Diagnostic plot of gamma log link model in DHARMa package

I used this formula in Rstudio: model<-glm (NRQ1~Sample, family= gamma (link= 'log'), data =df) and to check the model, I used ...
24 views

### Checking for homoskedasticity

In a linear regression model $Y=X \beta + \epsilon$ with $\epsilon \sim \mathcal N(0,\sigma^2I)$, we can check if this model is appropriate and fits well our observations by checking for ...
• 189
1 vote
33 views

### Singularity in Poisson GLMM - when is it better to switch to GLM?

I am analysing count data (count of observations per day of certain mammal species) at 12 different sites. My dataset consists of ~120 days of observations at each of the different sites. For each ...
24 views

### Residuals vs. Predictor Plot for categorical predictor

I am trying to use Residuals vs. Predictor Plot to evaluate whether to add a new categorical feature (with 2 levels) to my logistic regression. I found this useful page about how to use Residuals vs. ...
1 vote
28 views

### How to deal with non normality of residuals in VECM?

Does anyone know how to handle non normality of residuals in VECM? I have tried transforming the data into log, exp, and Box-cox but nothing has changed. Any suggestion will do. Thank you.
• 21
75 views

### Diagnostics in Spline Regression

In linear models, we do statistical tests (e.g. normality of residuals, homoskedasticity, autocorrelation, etc.). In spline regression, using the following method, we are running linear regression ...
• 215
54 views

### GAMM is producing irregular predicted probability

Predicted Probability of GAMM I've probably beaten this topic to death here, but I continue to have issues with model fitting. Thanks to the excellent advice here, I was able to at least square away ...
• 3,820
53 views

### Model diagnostic plots for anova test

Could you please help me in interpreting the model diagnostic plots? I feel there is a problem with the scale-location plot?
91 views

### Levene's Test and residuals vs. fitted plot lead to different interpretations about heteroscedasticity

I am performing a one-way ANOVA in R with the following data: Cu Day CC Cu1 49 30934500 Cu1 49 26860125 Cu1 49 46524750 Cu10 49 15272561 Cu10 49 31601659 Cu10 49 17627634 Cu100 49 3718127 ...
43 views

### Intuition behind martingale residuals and their properties in survival modeling

I am reading Tutz & Schmid "Modeling Discrete Time-to-Event Data" (2016) chapter 4 Evaluation and Model Choice section 4.2 Residuals and Goodness-of-Fit. A martingale residual is defined ...
1 vote
32 views

### Intuition behind the null distribution of the deviance statistic in survival models

I am reading Tutz & Schmid "Modeling Discrete Time-to-Event Data" (2016) chapter 4 Evaluation and Model Choice section 4.2 Residuals and Goodness-of-Fit. A goodness-of-fit statistic ...
15 views

### How do I interpret this Scale-location graph based on an anova?

I ran an anova using 1 categorical factor with 2 levels (Habitat: 1 and 2) and 1 continous factor (leaf carbon concentration)as the explanatory variables. The response variable is continous (...
131 views

### What is the hat matrix and why is it inappropriate for GLMM standardized residuals?

When I run this code to plot standardized residuals for a standard logistic regression: ...
• 3,820
1k views

### Is higher AUC always better?

Let's say we measure binary classifier performance by ROC graph, and we have two separate models with distinct AUC (The Area Under the Curve) values. Is the model with the higher AUC value always ...
• 361
88 views

### GLMM and BLUPs: high correlation between random effects in a logistic GLMM

Background: In an experiment, subjects had to choose whether they wanted an immediate reward or to wait for a larger reward (dichotomous dependent variable: yes/no). This choice was made multiple ...
• 63
40 views

### What kind of transformation should I do to improve my linear mixed model?

I asked in a previous post how to check the validity conditions of a linear mixed model I made, and here is the link. After additional diagnostics, I have the impression that the distribution of the ...
• 693
83 views

### How to properly diagnose a linear mixed model

I am trying to study the relationship between the type of bariatric surgery and weight loss. This is longitudinal data with different BMI measurements per patient. This the formula of the model: ...
• 693
1 vote
52 views

### Finding a fit for left-skewed continuous data

I am looking at various plant community traits and how they relate to a number of environmental variables in a woodland. I am using mixed models as some samples come from the same woodlands so I'm ...
37 views

### Confusing presentation of survival model diagnostics in Tutz & Schmid (2016)

I am reading Tutz & Schmid "Modeling Discrete Time-to-Event Data" (2016) chapter 4 Evaluation and Model Choice section 4.2 Residuals and Goodness-of-Fit. I got stuck on p. 78: The first ...
26 views

### OLS diagnostics in R

I conducted a OLS regression (N=2046) in R and I am a little unsure about the diagnostics. I reject the Shapiro-Wilk test and the Breusch-Pagan test, so this would mean no normality and ... 10 views

### When is single factor ANOVA regression checking out for model diagnostics?

Consider a simple randomized experiment with 4 treatments(no control) where the outcome of interest is difference between pre-treatment and post-treatment count. I want to conclude 4 treatments does ...
• 1,315
1 vote
26 views

### Is there some standard way to diagnose a structural time series model (also called simple unobserved components model)?

I am dealing with a structural time series model (also called a simple unobserved components model), and I wonder if there is some standard way to diagnose this sort of models. In most reference books ...
• 115
603 views

### Analysis of forecast errors from Facebook Prophet

I created a forecasting model Facebook Prophet and now trying to analyse the forecast errors (yhat - forecasted). Following are 3 graphs I plotted First one is raw forecast errors, second one is ...
1 vote
40 views

### non-constant variance of $\hat{\epsilon}$ against $\hat{y}$

In Faraways Linear Models (2ed.) page 77, he mention: "when non-constant variance is seen in the plot of $\hat{\epsilon}$ against $\hat{y}$", a transformation of the response $y$ to $h(y)$ ...
15 views

### Adjusting weighting and df for constant variance

Faraways Linear models (2ed), page 75, does the following: ...
125 views

### negative binomial glm: issues with model diagnostics when using offset term

I'm trying to model count data using a negative binomial glm with an offset in R and am having some issues with getting the model to fit properly when I use an offset term. Here is a reproducible ...
64 views

### Residual diagnostic for Boston Housing Dataset

I have some questions regarding the procedures for proper analysis of the "Boston Housing" dataset. My problem concerns the dysgnostics of the residuals and how to correct possible ...
• 1
97 views

### Linear and Ridge regression yield the same R² and MSE

I'm currently practicing on the NY taxi dataset but I'm having an issue and I'm sure it's because of some stupid mistake. After cleaning the dataset, I'm taking the following features and try to ...
• 25
332 views

### Objective criteria for assumption violations that do not utilize p-values?

Suppose we have a standard regression model and want to identify whether we have violated the assumptions of the model. Traditionally, we might utilize a significance test to determine whether (for ...
• 569
149 views

### DHARMa problems: Poisson or Zero-inflated negative binomial model?

I have a dataset of abundance of of rodent (AA) in 63 sites, which located in two main area (northern and southern part, NS). AA ...
200 views

### What does it mean when there is a pattern in residuals related to the dependent variable?

I created a linear regression model and realized I first need to check some assumptions. Autocorrelation not existing -> valid, since it is a between-subject experiment. Low collinearity between ...
1 vote
491 views

### parallel lines (cluster) in PCA plots (PC1 vs PC2)

There are about 20 subjects, 3 treatment groups, and 1000+ genes in my data; the 1000+ genes were processed in two batches. Could anyone comment on why I am seeing parallel lines/clusters in the PCA ...
• 63
8 views

### Which mixed model to use in this scenario?

I conducted an experiment in which I am trying to model the relationship between my response yield [dt/ha] and the predictors soil moisture [%] + weed coverage [%]+ treatment + distance (+ date) and ...
• 83
474 views

### Fixed effect instrumental variable (IV) regression with available diagnostic tests

May I please know an R package and code to run fixed effect instrumental variable (IV) regression with available diagnostic tests (e.g., weak instrument test, exogeneity test (using Wu-Hausman), ...
• 444
9 views

### Is there any Statistic method which could reflect the diagnose value when the prevalence of special type of characteristic is lower

Our present study is conducting a novel diagnosis test for predicting a disease by the X-ray. The gold-standard is a minimally invasive procedure can test a tissue sample for the disease. In our ...
1 vote
30 views

### Can we objectively determine whether assumptions have been violated in R?

I'm testing statistical assumptions in R and so far I've been using plot(model, which = c(1:6)), which produces six graphs for linearity, normality of errors, ...
1 vote
51 views

### OLS linearity assumptions

Do we have to check on stata that the OLS assumptions of linearity of a regression if the regression is already linear in parameters? I'm having trouble with this concept. Thanks in advance.
85 views

### Sample size for F1 score

I am developing a binary test and will be evaluating it based on the F1-score against a perfect reference standard. I want to calculate the sample size I'd need to have 80% power to be 95% confident ...
1 vote
30 views

### Impact of residuals on forecast

I'm working with ARMA models right now and I was wondering about the following case: If we have late significant lags in the residuals ACF and the rest of the earlier residual lags weren't significant,...
• 89
222 views

### Optimal lag length in VAR/VECM: IC or Residual test?

I read so many answers in here that I should use IC(information criteria) to determine the optimal lag length in VAR/VECM. But also it is important to check the residual of VAR/VECM has no-...
1 vote
442 views

### What are the assumptions of MLE and how to test them using residuals?

When using ordinary least square (OLS) method, there are certain residual diagnostics that need to be performed. In a similar manner, what diagnostics should be performed when using Maximum Likelihood ...
• 119
1 vote
169 views

### Are ARIMA model residuals normally distributed

I am running the ARIMA model using python's package: sm.tsa.statespace.SARIMAX. I get the following results. As we can see, the ...
• 121
1 vote
171 views

### Is correlation matrix of residuals , a method to check for autocorrelation of residuals in the model?

I am modelling and forecasting using a factor augmented VAR. I got the following residual matrix after fitting the model. My question is how to interpret it and does it indicate any autocorrelations ...
• 119
43 views

### The different usage of ROC between diagnotic tests and machine learning

I am currently very confused about the ROC usage in diagnostic tests and machine learning. In the scenario of medical diagnostic studies, many tutorial does not mention the data split procedure as ...
• 45
18 views

### Model diagnostic plots [duplicate]

i have built a predictive model and these are the model diagnostic. How do i interpret them? it looks like the model is linear based on the residuals vs fitted plot. but what about others? 