1
$\begingroup$

I have a dataset where I am comparing two variables, activity is dependent and days_existed is independent. The correlation between the two variables is 0.41 and I ran an OLS linear regression analysis then plotted the results.

R-squared is 0.15 and p-value for dependent variable is 0.000, the intercept coefficient is negative.

What else should I be looking at that could be important in determining is there is a relationship between the two variables?

Here is the plotted regression line, it looks like the model is wrong to me. enter image description here

$\endgroup$
3
  • $\begingroup$ Why is your fitted model not a straight line? Shouldn't it be considering that you are using a linear model? $\endgroup$
    – B.Shankar
    Commented May 25, 2015 at 1:13
  • $\begingroup$ Yes, sorry, I posted the wrong screenshot! I've changed it now. $\endgroup$
    – birkin
    Commented May 25, 2015 at 1:25
  • $\begingroup$ With only one IV, the $R^2$ value should be the square of the correlation between IV and DV, and $0.41^2 > 0.16$, yet you report an $R^2$ of $0.15$. How is that possible? Are you looking at adjusted $R^2$?. $\endgroup$
    – Glen_b
    Commented May 25, 2015 at 1:32

1 Answer 1

1
$\begingroup$

I perceive a number of potential problems.

  1. Your response appears to be a count, and in any case cannot be negative; ordinary linear regression will necessarily be negative somewhere, so something like a negative intercept shouldn't be a surprise.

  2. Further, the assumption of constant variance won't hold - if the mean is close to 0, non-negative data will tend to squish up near the axis (have low variability), while where the mean is large there will tend to be more variability.

  3. As the mean becomes smaller, the true mean relationship cannot plow down through 0; you would therefore expect it to curve so that the mean doesn't enter an impossible region.

  4. The plot seems to hint that there's a degree of clumpiness in the distribution that might perhaps suggest other important predictors.

  5. If these are observations over time, there may be dependence over time (autocorrelation)

These observations suggest ordinary linear regression is unsuitable.

It may be that something more like a GLM with a log-link would be more suitable; perhaps a negative binomial wouldn't be too poor, possibly zero-inflated. (I wouldn't try a Poisson GLM - the variation looks to be much too large relative to the mean.) However, I don't think that can deal with the apparent clumpiness nor with time dependence; some additional investigation (and likely, larger models) would be needed to address those adequately.

$\endgroup$
4
  • $\begingroup$ Thank you for your answer! I am not planning on using the regression to build a predictive model, I would just like to understand if the relationship between two variables holds or not, so I am not very worried about the regression being negative somewhere. I will try GÉM with a log-link.If my variables seem to follow an exponential/pareto distribution, should I take the logs of the data before I do anything? As far as I know, OLS regression doesn't necessitate that. $\endgroup$
    – birkin
    Commented May 25, 2015 at 11:01
  • $\begingroup$ Sorry, I'm not familiar with this "GEM" you mention. What's that? When you say you'd "like to understand if the relationship between two variables holds or not", how are you going to do that? Are you planning to do any hypothesis tests, for example? When you say "If my variables seem to follow an exponential/pareto distribution" ... which variables are you talking about and why does their distribution matter? In relation to your last sentence, OLS regression assumes that the relationships are linear. This doesn't seem to be a reasonable description of the data. $\endgroup$
    – Glen_b
    Commented May 25, 2015 at 11:27
  • $\begingroup$ Sorry, you are right, I wasn't being very understandable. I have two variables, days_existed which shows for each of my 80 observations, how many days the given account has existed. A lot of the accounts have existed for very long, and the number of accounts that have existed for shorter lengths decreases drastically with each decrease in days_existed. This is also true for my other variable, which depicts the numbers of actions that the given account has taken. I would like to answer the following question: Do accounts that have existed for a longer time tend to have taken more actions? $\endgroup$
    – birkin
    Commented May 25, 2015 at 12:00
  • $\begingroup$ Ah; you should edit that information into your question. You might consider looking at something like a monotonic correlation (such as Kendall's tau), and perhaps consider using a permutation test with it (so that the potential effect of discreteness doesn't adversely impact the significance level, though it probably won't make all that much difference). $\endgroup$
    – Glen_b
    Commented May 25, 2015 at 12:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.