# Questions tagged [regression]

Techniques for analyzing the relationship between one (or more) "dependent" variables and "independent" variables.

24,277 questions
Filter by
Sorted by
Tagged with
2k views

### Explicit formulation of predict() output of an orthogonal polynomial regression?

In R, I am trying to reproduce the predict() output value of the orthogonal polynomial regression below. Based on my understanding of polynomial regression, I get 0.03869436 which is different from 0....
235 views

### Computing regression coefficient values in OLS

I have a question on testing the hypothesis that a particular regression coefficient in a simple OLS scheme with all the good assumptions is zero or not. In particular eq 3.12, in the book by ...
41k views

### Is it valid to include a baseline measure as control variable when testing the effect of an independent variable on change scores?

I am attempting to run an OLS regression: DV: Change in weight over a year (initial weight - end weight) IV: Whether or not you exercise. However, it seems reasonable that heavier people will lose ...
45k views

### How to calculate linear regression with Libre Office? [closed]

Libre Office has an easy way to calculate and show trade line in a graphic (i.e. right-click on data series and insert trend line). Formatting the graphic this way however is not really easy because ...
784 views

### p-value for nonlinear equation

For example I have vectX and vectY, and I want to know: Which is the better model fitting for my data -- it can be linear, ...
162 views

### Subdividing a dataset

I know I can subdivide a dataset by socio-demographic factors such as gender, age, income level etc. and analyse the responses for each set separately and then compare the results. For example, I am ...
1k views

### Survey regression in R with singleton PSUs

I am completely new to R, just downloaded and installed it today. I am familiar with SAS and Stata; I am using R because I have found out that in survey regression analysis, R is capable of using data ...
10k views

### vcovHC, vcovHAC, NeweyWest – which function to use?

I am trying to update my lm() based model to get correct standard errors and tests. I am really confused which VC matrix to use. The sandwich package offers ...
2k views

### What is wrong with lagged regressor in time series regression?

I am trying to explain a time series with the help of other related series. I really get nice fits using a standard LM approach with NeweyWest VC matrix. The fit even increases drastically when I ...
2k views

### Volatility of x and y variables in linear regression?

I have a simple regression with price returns: $r_{t+1} = \alpha + \beta r_t + \epsilon$ My question is: do I need to do anything if $r_{t+1}$ and $r_t$ are over different horizons? Suppose the x-...
1k views

### What “more” does differencing (d>0) do in ARIMA than detrend?

I recently read a discussion about ARIMA models where someone said (referring to d as in ARIMA (p, d, q)): Its true that d=1 takes out deterministic trends when they are present (they would ...
8k views

### Estimating the intersection of two lines

I have two datasets, A and B, of weighted (x,y) pairs. I computed the best fit lines, L_A and L_B, respectively, of these datasets, and then computed the intersection of these two lines, (x*,y*). Now,...
6k views

### How do joint test, r-squared behave when using autocorrelation / heteroskedasticity robust std. errors?

Recently we discussed on SO how to update a standard linear regression summary with NeweyWest standard errors. I used coeftestfrom the ...
6k views

### Kruskal-Wallis or Fligner test to check homogeneity of variances?

I need to check the homogeneity of variances on the residuals of a linear regression. I read that Kruskal is also good without assuming a normal-distribution. But I don't know if it's good in my case. ...
13k views

### Whether to delete cases that are flagged as outliers by statistical software when performing multiple regression?

I am performing multiple regression analyses and I am not sure whether outliers in my data should be deleted. The data I am concerned about appear as "circles" on the SPSS boxplots, however there are ...
20k views

### How dummy variable can be analyzed in panel data using fixed effects in Stata?

I have problems regarding analyzing dummy variable using fixed effects in Stata. I am doing research on impact of climate change in food grain production. Much previous literature states that panel ...
691 views

### Calculating 90% confidence intervals in regression to identify outlying data

I have been searching for the answer for a problem with confidence intervals for a long time now, so I hope someone can help! The two psychological papers below performed the same analysis, ...
9k views

### Does the order of explanatory variables in logistic regression change the results?

I am curious about the consequences of changing the order of the explanatory variables in a binary logistic regression. In a recent series of logistic regressions I ran in SPSS, I found that changing ...
2k views

### Chi-square test for checking if values are close to zero?

I have a number of set of data points. For each set I have done linear regression to find the lines of best fit for the data. I hypothesise that the gradients of all the lines of best fit should be ...
1k views

### Testing regime change in SAS

I have two samples, A and B. I run the same model for A and B separately to obtain the estimates. I now want to test whether the parameters for models in A are the same with the parameters in B using ...
40 views

### Analysis of influence against weighted edges and attributes

I have network data of organizations and weighted links between these organisations, the weight indicates level of trade between these organisations. I have attribute files against each organisation ...
149 views

### Constraining linear regression to yield nonpositive residuals

Is there any literature on linear regression analysis where we require that our residuals are non-positive? That is, we are interested in minimising: $\sum_i \max(y_i - b x_i,0)$ EDIT: The ...
5k views

### Should the difference between control and treatment be modelled explicitly or implicitly?

Given the following experimental setup: Multiple samples are taken from a subject and each sample is treated multiple ways (including a control treatment). What is mainly interesting is the ...
359 views

### How to accurately quantify forecast uncertainty in a special case of robust linear regression?

If I'm using OLS linear regression, and I want to know the uncertainty of my forecasts I can quantify it using residuals (MSE, median absolute deviation, etc). But if I'm using robust linear ...
456 views

### Inference in linear model with conditional heteroskedasticity

Suppose I observe independent variable vectors $\vec{x}$ and $\vec{z}$ and dependent variable $y$. I would like to fit a model of the form: y = \vec{x}^{\top}\vec{\beta_1} + \sigma g\left(\vec{z}^{\...
4k views

### The “sum” of prediction intervals

Suppose I have a regression model which yields a couple of predicted values with their respective prediction intervals and the random quantity that I am interested in is the sum of (some subset) of ...
606 views

### What is an analogue of PCA in the regression context?

I'm writing code to approximate a function $y=f(\vec{x})$ where $y\in\mathbb{R}$ and $\vec{x}\in\mathbb{R}^N$ for medium-sized $N$ ($N$ between 20 and 50, approx.). I have a ton of examples, however, ...
141 views

### How do I control for a confounding variable with this distribution?

The short version of my question is: How is it possible to control for a confounding variable that has a Dirichlet distribution? Suppose I have electoral and census data for a large set of cities. In ...
3k views

### Iterate through levels of different factors by means of regression

I am a newbie in R programming. I think for most of you my question is a rather simple one. My regression problem is as follows: I have a dataframe containing several numerical attributes and ...
4k views

### Meaning of p-values in regression

When I perform a linear regression in some software packages (for example Mathematica), I get p-values associated with the individual parameters in the model. For, instance the results of a linear ...
104k views

### How to test the autocorrelation of the residuals?

I have a matrix with two columns that have many prices (750). In the image below I plotted the residuals of the follow linear regression: ...
265 views

### How to test the effect of condition on change scores for a possibly ordinal dependent variable?

I have a categorical independent variable (two levels: condition 1; condition 2) and ordinal(?) dependent variables (numerical magnitude shifts (e.g. -3 if there was a decrease in number magnitude ...
1k views

### Poisson regression instead of log transformation of a continuous outcome variable? [duplicate]

Possible Duplicate: Poisson regression vs. log-count least-squares regression? This post got me to thinking about when it makes sense to use poisson regression instead of log transforming a ...
291 views

### Is it allowed to incorporate static covariates in Mixed effects models with time series data?

I was recently told that it is not allowed to include static covariates in mixed effect models. I can believe that this could be true, however, when I have time series data, and season is a grouping ...
2k views

176 views

### Elliptic regression, basic conceptual question

I'm considering circular regression and elliptic regression on a computational and conceptual basis. If we fit an ellipse to our data then we deal with the principal components as reference for the ...
64k views

### How can a regression be significant yet all predictors be non-significant? [duplicate]

My multiple regression analysis model has a statistically significant F value however all beta values are statistically non-significant. All the regression assumptions are met. No multicollinearity ...
324 views

### Logarithms and regression

I have a regression where I am trying to predict Y, using several variables. My variables are A, B, C. I'm using R for my analysis. My equation is as follows: <...